找不到R%。%函数

找不到R%。%函数,r,function,R,Function,我想复制一下: 但我收到以下错误: Error: could not find function "%.%" 编辑 changing it to %>% solved the problem. 现在我收到另一个错误: Error in n() : This function should not be called directly 解决方案 我通过添加dplyr:: dplyr::summarise(companies=n(),... 以下是可复制的数据: structure(

我想复制一下:

但我收到以下错误:

Error: could not find function "%.%"
编辑

changing it to %>% solved the problem. 
现在我收到另一个错误:

Error in n() : This function should not be called directly
解决方案 我通过添加dplyr::

dplyr::summarise(companies=n(),...
以下是可复制的数据:

structure(list(company_permalink = c("/organization/-fame","/organization/hashoff", "/organization/waywire", "/organization/tv-communications", "/organization/tv-communications"), company_name = c("#fame", "#HASHOFF", "#waywire", "&TV Communications","&TV Communications"), company_category_list = c("|Media|", "|Digital Media|Internet|Social Media|","|Entertainment|Politics|Social Media|News|", "|Games|", "|Games|"), company_market = c("Media", "Digital Media", "News", "Games","Games"), company_country_code = c("IND", "USA", "USA", "USA", "USA"), company_state_code = c("", "CO", "NY", "CA", "CA"), company_region = c("Mumbai", "Denver", "New York City", "Los Angeles", "Los Angeles"), company_city = c("Mumbai", "Denver", "New York", "Los Angeles", "Los Angeles"), funding_round_permalink = c("/funding-round/9a01d05418af9f794eebff7ace91f638", "/funding-round/669d6203c0374e6cf0e8d10f75ba0b8a", "/funding-round/cc409188fa2b63482bd9008f682c2efa", "/funding-round/86d22afc65107b6941e6c43c671ecbb8", "/funding-round/59a3669a64e39360c2b939300bcda162"), funding_round_type = c("venture", "debt_financing", "seed", "venture", "venture"), funding_round_code = c("B", "", "", "", ""), funded_at = c("2015-01-05", "2014-12-08", "2012-06-30", "2010-06-04", "2010-09-23"), funded_month = c("2015-01", "2014-12", "2012-06", "2010-06", "2010-09"), funded_quarter = c("2015-Q1", "2014-Q4", "2012-Q2", "2010-Q2", "2010-Q3"), funded_year = c(2015L, 2014L, 2012L, 2010L, 2010L), raised_amount_usd = c(" \t10.000.000 ", " \t455.000 ", " \t1.750.000 ", " \t1.000.000 ", " \t3.000.000 "), X = c(NA, NA, NA, NA, NA)), .Names = c("company_permalink", "company_name", "company_category_list", "company_market", "company_country_code", "company_state_code", "company_region", "company_city", "funding_round_permalink", "funding_round_type", "funding_round_code", "funded_at", "funded_month", "funded_quarter", "funded_year", "raised_amount_usd", "X"), class = c("data.table", "data.frame"), row.names = c(NA, -5L), .internal.selfref = <pointer: 0x10180d178>)
结构(列表(company_permalink=c(“/organization/-fame”、“/organization/hashoff”、“/organization/waywire”、“/organization/tv communications”、“/organization/tv communications”、“/organization/tv communications”)、company_name=c(“#fame”、“#hashoff”、“#waywire”、“&tv communications”、“&tv communications”)、company#类别列表=c(“,“|数字媒体|互联网|社交媒体|”、“|娱乐|政治|社交媒体|新闻|”、“|游戏|”、“|游戏|”、“媒体”、“数字媒体”、“新闻”、“游戏”、“游戏”、公司|国家|代码=c(“IND”、“USA”、“USA”、“USA”、“USA”、“USA”)、公司|州|代码=c(“CO”、“CO”、“NY”、“CA”、“CA”、“CA”)、公司|地区=c(“孟买”、“纽约市”、“丹佛市”)洛杉矶、洛杉矶)、公司(孟买、丹佛、纽约、洛杉矶、洛杉矶)、融资(permalink=c)(“融资轮/9a01d05418af9f794eebff7ace91f638”,“融资轮/669D6203C03C0374E6CF0E8D10F75BA0B8A”,“融资轮/cc409188fa2b63482bd9008f682c2efa”,“融资轮/86D22AFC6107B6941C43C671ECBB8”,“融资轮//融资轮/59a3669a64e39360c2b939300bcda162)、融资轮类型=c(“风险”、“债务融资”、“种子”、“风险”、“风险”)、融资轮代码=c(“B”、“B”、“2012”、“2012”、“2012”、“2006”、“2010-06”、“2010-09-23”)、融资月=c(“2015-01”、“2014-12-05”、“2014-12-08”、“2012-06-30”、“2010-06-04”、“2010-09-23”),供资季度=c(“2015-Q1”、“2014-Q4”、“2012-Q2”、“2010-Q2”、“2010-Q3”)、供资年度=c(2015L、2014L、2012L、2010L、2010L、2010L)、募集金额=c(“\t10.000.000”、“\t455.000”、“\t1.750.000”、“\t1.000.000”、“\t3.000.000”)、X=c(不适用、不适用、不适用、不适用)、名称=c(“公司名称”、“公司名称”、“公司类别清单”“公司市场”、“公司国家代码”、“公司州代码”、“公司地区”、“公司城市”、“融资周期”、“融资周期类型”、“融资周期代码”、“融资时间”、“融资月份”、“融资季度”、“融资年度”、“募集资金金额”、“X”),class=c(“data.table”、“data.frame”),row.names=c(NA,-5L),.internal.selfref=)

将其更改为
%>%
%。%
是该脚本的旧版本,请参阅:谢谢,解决了问题。不幸的是,我在同一行中收到另一个错误22请通过共享一些数据来举例。检查编辑,我添加了一些可复制的数据。我不会调试所有脚本…请更新您的问题,so它包含重现单个问题的代码(您共享的数据会导致其他问题,您的问题中没有描述)。