问题
I am very new to R but seem to be getting this error more and more frequently, especially when using the pipe operator:
"Error:
...
is not empty. We detected these problematic arguments: *logical
These dots only exist to allow future extensions and should be empty.
Did you misspecify an argument?"
I even get it on simple functions like select
as in:
HM_74_Duplicates_test <- HM_74_Duplicates %>%
select(State)
HM_74_Duplicates
is loaded as a data.frame
, tidyverse
is in library.
What am I doing wrong?
HM74_1 <- read.csv("/Users/spencepurnell/Downloads/hm74_r - Base_Sheet.csv")
HM74_1 <- as.data.frame(HM74_1)
#Convert Appropriate Metrics to Numeric
HM74_1$Total.Interstate <- as.numeric(gsub(",","", HM74_1$Total.Interstate))
HM74_1$Total.OFE <- as.numeric(gsub(",","", HM74_1$Total.OFE))
HM74_1$Total.OPA <- as.numeric(gsub(",","", HM74_1$Total.OPA))
HM74_1$Total.Arterial..Minor. <- as.numeric(gsub(",","", HM74_1$Total.Arterial..Minor.))
#Creates new True/False Coolumn for duplicate variables where TRUE = DUPLICATE
HM74_1 <- HM74_1 %>%
group_by(Federal.Area) %>%
mutate(duplicate.flag = n() > 1) %>%
ungroup()
#Creates df of duplicates using new TRUE/FAlSE column
HM_74_Duplicates <- HM74_1 %>%
filter(duplicate.flag == TRUE)
#Duplicates as data.frame
HM_74_Duplicates <- as.data.frame(HM_74_Duplicates)
#Select State
HM_74_Duplicates_Test <- HM_74_Duplicates %>%
select(State)
#dput
dput(HM_74_Duplicates)
Here is the output from dput:
structure(list(Federal.Area = structure(c(10L, 10L, 29L, 29L,
42L, 42L, 46L, 46L, 55L, 55L, 60L, 60L, 69L, 69L, 80L, 80L, 82L,
82L, 84L, 84L, 86L, 86L, 86L, 87L, 87L, 95L, 95L, 104L, 104L,
104L, 110L, 110L, 123L, 123L, 125L, 125L, 126L, 126L, 128L, 128L,
134L, 134L, 132L, 132L, 138L, 138L, 142L, 142L, 144L, 144L, 153L,
153L, 162L, 162L, 166L, 166L, 179L, 179L, 179L, 199L, 199L, 199L,
222L, 222L, 226L, 226L, 231L, 231L, 251L, 251L, 264L, 264L, 286L,
286L, 286L, 289L, 289L, 294L, 294L, 309L, 309L, 312L, 312L, 318L,
318L, 318L, 322L, 322L, 328L, 328L, 336L, 336L, 338L, 338L, 341L,
341L, 341L, 341L, 353L, 353L, 354L, 354L, 356L, 356L, 358L, 358L,
381L, 381L, 411L, 411L, 411L, 414L, 414L, 420L, 420L, 426L, 426L,
427L, 427L, 437L, 437L, 441L, 441L, 465L, 465L, 467L, 467L, 467L,
473L, 473L, 473L, 477L, 477L, 487L, 487L, 491L, 491L), .Label = c("Aberdeen--Bel Air South--Bel Air North, MD",
"Abilene, TX", "Aguadilla--Isabela--San Sebastian, PR", "Akron, OH",
"Albany--Schenectady, NY", "Albany, GA", "Albany, OR", "Albuquerque, NM",
"Alexandria, LA", "Allentown, PA--NJ", "Alton, IL--MO", "Altoona, PA",
"Amarillo, TX", "Ames, IA", "Anchorage, AK", "Anderson, IN",
"Anderson, SC", "Ann Arbor, MI", "Anniston--Oxford, AL", "Antioch, CA",
"Appleton, WI", "Arecibo, PR", "Arroyo Grande--Grover Beach, CA",
"Asheville, NC", "Athens-Clarke County, GA", "Atlanta, GA", "Atlantic City, NJ",
"Auburn, AL", "Augusta-Richmond County, GA--SC", "Austin, TX",
"Avondale--Goodyear, AZ", "Bakersfield, CA", "Baltimore, MD",
"Bangor, ME", "Barnstable Town, MA", "Baton Rouge, LA", "Battle Creek, MI",
"Bay City, MI", "Beaumont, TX", "Beckley, WV", "Bellingham, WA",
"Beloit, WI--IL", "Bend, OR", "Benton Harbor--St. Joseph--Fair Plain, MI",
"Billings, MT", "Binghamton, NY--PA", "Birmingham, AL", "Bismarck, ND",
"Blacksburg, VA", "Bloomington--Normal, IL", "Bloomington, IN",
"Bloomsburg--Berwick, PA", "Boise City, ID", "Bonita Springs, FL",
"Boston, MA--NH--RI", "Boulder, CO", "Bowling Green, KY", "Bremerton, WA",
"Bridgeport--Stamford, CT--NY", "Bristol--Bristol, TN--VA", "Brownsville, TX",
"Brunswick, GA", "Buffalo, NY", "Burlington, NC", "Burlington, VT",
"Camarillo, CA", "Canton, OH", "Cape Coral, FL", "Cape Girardeau, MO--IL",
"Carbondale, IL", "Carson City, NV", "Cartersville, GA", "Casa Grande, AZ",
"Casper, WY", "Cedar Rapids, IA", "Chambersburg, PA", "Champaign, IL",
"Charleston--North Charleston, SC", "Charleston, WV", "Charlotte, NC--SC",
"Charlottesville, VA", "Chattanooga, TN--GA", "Cheyenne, WY",
"Chicago, IL--IN", "Chico, CA", "Cincinnati, OH--KY--IN", "Clarksville, TN--KY",
"Cleveland, OH", "Cleveland, TN", "Coeur d'Alene, ID", "College Station--Bryan, TX",
"Colorado Springs, CO", "Columbia, MO", "Columbia, SC", "Columbus, GA--AL",
"Columbus, IN", "Columbus, OH", "Concord, CA", "Concord, NC",
"Conroe--The Woodlands, TX", "Conway, AR", "Corpus Christi, TX",
"Corvallis, OR", "Cumberland, MD--WV--PA", "Dallas--Fort Worth--Arlington, TX",
"Dalton, GA", "Danbury, CT--NY", "Danville, IL", "Daphne--Fairhope, AL",
"Davenport, IA--IL", "Davis, CA", "Dayton, OH", "Decatur, AL",
"Decatur, IL", "DeKalb, IL", "Delano, CA", "Deltona, FL", "Denton--Lewisville, TX",
"Denver--Aurora, CO", "Des Moines, IA", "Detroit, MI", "Dothan, AL",
"Dover--Rochester, NH--ME", "Dover, DE", "Dubuque, IA--IL", "Duluth, MN--WI",
"Durham, NC", "East Stroudsburg, PA--NJ", "Eau Claire, WI", "El Centro--Calexico, CA",
"El Paso de Robles (Paso Robles)--Atascadero, CA", "El Paso, TX--NM",
"Elizabethtown--Radcliff, KY", "Elkhart, IN--MI", "Elmira, NY",
"Erie, PA", "Eugene, OR", "Evansville, IN--KY", "Fairbanks, AK",
"Fairfield, CA", "Fajardo, PR", "Fargo, ND--MN", "Farmington, NM",
"Fayetteville--Springdale--Rogers, AR--MO", "Fayetteville, NC",
"Flagstaff, AZ", "Flint, MI", "Florence, AL", "Florence, SC",
"Florida--Imbery--Barceloneta, PR", "Fond du Lac, WI", "Fort Collins, CO",
"Fort Smith, AR--OK", "Fort Walton Beach--Navarre--Wright, FL",
"Fort Wayne, IN", "Frederick, MD", "Fredericksburg, VA", "Fresno, CA",
"Gadsden, AL", "Gainesville, FL", "Gainesville, GA", "Gastonia, NC--SC",
"Gilroy--Morgan Hill, CA", "Glens Falls, NY", "Goldsboro, NC",
"Grand Forks, ND--MN", "Grand Island, NE", "Grand Junction, CO",
"Grand Rapids, MI", "Grants Pass, OR", "Great Falls, MT", "Greeley, CO",
"Green Bay, WI", "Greensboro, NC", "Greenville, NC", "Greenville, SC",
"Guayama, PR", "Gulfport, MS", "Hagerstown, MD--WV--PA", "Hammond, LA",
"Hanford, CA", "Hanover, PA", "Harlingen, TX", "Harrisburg, PA",
"Harrisonburg, VA", "Hartford, CT", "Hattiesburg, MS", "Hazleton, PA",
"Hemet, CA", "Hickory, NC", "High Point, NC", "Hilton Head Island, SC",
"Hinesville, GA", "Holland, MI", "Homosassa Springs--Beverly Hills--Citrus Springs, FL",
"Hot Springs, AR", "Houma, LA", "Houston, TX", "Huntington, WV--KY--OH",
"Huntsville, AL", "Idaho Falls, ID", "Indianapolis, IN", "Indio--Cathedral City, CA",
"Iowa City, IA", "Ithaca, NY", "Jackson, MI", "Jackson, MS",
"Jackson, TN", "Jacksonville, FL", "Jacksonville, NC", "Janesville, WI",
"Jefferson City, MO", "Johnson City, TN", "Johnstown, PA", "Jonesboro, AR",
"Joplin, MO", "Juana Diaz, PR", "Kahului, HI", "Kailua (Honolulu County)--Kaneohe, HI",
"Kalamazoo, MI", "Kankakee, IL", "Kansas City, MO--KS", "Kennewick--Pasco, WA",
"Kenosha, WI--IL", "Killeen, TX", "Kingsport, TN--VA", "Kingston, NY",
"Kissimmee, FL", "Knoxville, TN", "Kokomo, IN", "La Crosse, WI--MN",
"Lady Lake--The Villages, FL", "Lafayette--Louisville--Erie, CO",
"Lafayette, IN", "Lafayette, LA", "Lake Charles, LA", "Lake Havasu City, AZ",
"Lake Jackson--Angleton, TX", "Lakeland, FL", "Lancaster--Palmdale, CA",
"Lancaster, PA", "Lansing, MI", "Laredo, TX", "Las Cruces, NM",
"Las Vegas--Henderson, NV", "Lawrence, KS", "Lawton, OK", "Lebanon, PA",
"Leesburg--Eustis--Tavares, FL", "Leominster--Fitchburg, MA",
"Lewiston, ID--WA", "Lewiston, ME", "Lexington Park--California--Chesapeake Ranch Estates, MD",
"Lexington-Fayette, KY", "Lima, OH", "Lincoln, NE", "Little Rock, AR",
"Livermore, CA", "Lodi, CA", "Logan, UT", "Lompoc, CA", "Longmont, CO",
"Longview, TX", "Longview, WA--OR", "Lorain--Elyria, OH", "Los Angeles--Long Beach--Anaheim, CA",
"Los Lunas, NM", "Louisville/Jefferson County, KY--IN", "Lubbock, TX",
"Lynchburg, VA", "Macon, GA", "Madera, CA", "Madison, WI", "Manchester, NH",
"Mandeville--Covington, LA", "Manhattan, KS", "Mankato, MN",
"Mansfield, OH", "Manteca, CA", "Marysville, WA", "Mauldin--Simpsonville, SC",
"Mayagüez, PR", "McAllen, TX", "McKinney, TX", "Medford, OR",
"Memphis, TN--MS--AR", "Merced, CA", "Miami, FL", "Michigan City--La Porte, IN--MI",
"Middletown, OH", "Midland, MI", "Midland, TX", "Milwaukee, WI",
"Minneapolis--St. Paul, MN--WI", "Mission Viejo--Lake Forest--San Clemente, CA",
"Missoula, MT", "Mobile, AL", "Modesto, CA", "Monessen--California, PA",
"Monroe, LA", "Monroe, MI", "Montgomery, AL", "Morgantown, WV",
"Morristown, TN", "Mount Vernon, WA", "Muncie, IN", "Murrieta--Temecula--Menifee, CA",
"Muskegon, MI", "Myrtle Beach--Socastee, SC--NC", "Nampa, ID",
"Napa, CA", "Nashua, NH--MA", "Nashville-Davidson, TN", "New Bedford, MA",
"New Bern, NC", "New Haven, CT", "New Orleans, LA", "New York--Newark, NY--NJ--CT",
"Newark, OH", "Norman, OK", "North Port--Port Charlotte, FL",
"Norwich--New London, CT--RI", "Ocala, FL", "Odessa, TX", "Ogden--Layton, UT",
"Oklahoma City, OK", "Olympia--Lacey, WA", "Omaha, NE--IA", "Orlando, FL",
"Oshkosh, WI", "Owensboro, KY", "Oxnard, CA", "Palm Bay--Melbourne, FL",
"Palm Coast--Daytona Beach--Port Orange, FL", "Panama City, FL",
"Parkersburg, WV--OH", "Pascagoula, MS", "Pensacola, FL--AL",
"Peoria, IL", "Petaluma, CA", "Philadelphia, PA--NJ--DE--MD",
"Phoenix--Mesa, AZ", "Pine Bluff, AR", "Pittsburgh, PA", "Pittsfield, MA",
"Pocatello, ID", "Ponce, PR", "Port Arthur, TX", "Port Huron, MI",
"Port St. Lucie, FL", "Porterville, CA", "Portland, ME", "Portland, OR--WA",
"Portsmouth, NH--ME", "Pottstown, PA", "Poughkeepsie--Newburgh, NY--NJ",
"Prescott Valley--Prescott, AZ", "Providence, RI--MA", "Provo--Orem, UT",
"Pueblo, CO", "Racine, WI", "Raleigh, NC", "Rapid City, SD",
"Reading, PA", "Redding, CA", "Reno, NV--CA", "Richmond, VA",
"Riverside--San Bernardino, CA", "Roanoke, VA", "Rochester, MN",
"Rochester, NY", "Rock Hill, SC", "Rockford, IL", "Rocky Mount, NC",
"Rome, GA", "Round Lake Beach--McHenry--Grayslake, IL--WI", "Sacramento, CA",
"Saginaw, MI", "Salem, OR", "Salinas, CA", "Salisbury, MD--DE",
"Salt Lake City--West Valley City, UT", "San Angelo, TX", "San Antonio, TX",
"San Diego, CA", "San Francisco--Oakland, CA", "San Germán--Cabo Rojo--Sabana Grande, PR",
"San Jose, CA", "San Juan, PR", "San Luis Obispo, CA", "San Marcos, TX",
"Santa Barbara, CA", "Santa Clarita, CA", "Santa Cruz, CA", "Santa Fe, NM",
"Santa Maria, CA", "Santa Rosa, CA", "Sarasota--Bradenton, FL",
"Saratoga Springs, NY", "Savannah, GA", "Scranton, PA", "Seaside--Monterey, CA",
"Seattle, WA", "Sebastian--Vero Beach South--Florida Ridge, FL",
"Sebring--Avon Park, FL", "Sheboygan, WI", "Sherman, TX", "Shreveport, LA",
"Sierra Vista, AZ", "Simi Valley, CA", "Sioux City, IA--NE--SD",
"Sioux Falls, SD", "Slidell, LA", "South Bend, IN--MI", "South Lyon--Howell, MI",
"Spartanburg, SC", "Spokane, WA", "Spring Hill, FL", "Springfield, IL",
"Springfield, MA--CT", "Springfield, MO", "Springfield, OH",
"St. Augustine, FL", "St. Cloud, MN", "St. George, UT", "St. Joseph, MO--KS",
"St. Louis, MO--IL", "State College, PA", "Staunton--Waynesboro, VA",
"Stockton, CA", "Sumter, SC", "Syracuse, NY", "Tallahassee, FL",
"Tampa--St. Petersburg, FL", "Temple, TX", "Terre Haute, IN",
"Texarkana--Texarkana, TX--AR", "Texas City, TX", "Thousand Oaks, CA",
"Titusville, FL", "Toledo, OH--MI", "Topeka, KS", "Tracy, CA",
"Trenton, NJ", "Tucson, AZ", "Tulsa, OK", "Turlock, CA", "Tuscaloosa, AL",
"Twin Rivers--Hightstown, NJ", "Tyler, TX", "Uniontown--Connellsville, PA",
"Urban Honolulu, HI", "Utica, NY", "Vacaville, CA", "Valdosta, GA",
"Vallejo, CA", "Victoria, TX", "Victorville--Hesperia, CA", "Villas, NJ",
"Vineland, NJ", "Virginia Beach, VA", "Visalia, CA", "Waco, TX",
"Waldorf, MD", "Walla Walla, WA--OR", "Warner Robins, GA", "Washington, DC--VA--MD",
"Waterbury, CT", "Waterloo, IA", "Watertown, NY", "Watsonville, CA",
"Wausau, WI", "Weirton--Steubenville, WV--OH--PA", "Wenatchee, WA",
"West Bend, WI", "Westminster--Eldersburg, MD", "Wheeling, WV--OH",
"Wichita Falls, TX", "Wichita, KS", "Williamsburg, VA", "Williamsport, PA",
"Wilmington, NC", "Winchester, VA", "Winston-Salem, NC", "Winter Haven, FL",
"Woodland, CA", "Worcester, MA--CT", "Yakima, WA", "Yauco, PR",
"York, PA", "Youngstown, OH--PA", "Yuba City, CA", "Yuma, AZ--CA"
), class = "factor"), State = structure(c(32L, 39L, 11L, 42L,
15L, 50L, 35L, 39L, 20L, 31L, 44L, 47L, 15L, 25L, 28L, 42L, 11L,
44L, 15L, 16L, 16L, 18L, 36L, 18L, 44L, 2L, 11L, 21L, 39L, 51L,
13L, 15L, 22L, 31L, 13L, 15L, 24L, 50L, 32L, 39L, 16L, 23L, 33L,
45L, 16L, 18L, 24L, 29L, 3L, 25L, 3L, 37L, 28L, 42L, 24L, 29L,
21L, 39L, 51L, 18L, 36L, 51L, 17L, 25L, 44L, 47L, 24L, 50L, 14L,
49L, 38L, 49L, 3L, 26L, 44L, 16L, 23L, 24L, 50L, 28L, 42L, 20L,
31L, 7L, 32L, 35L, 7L, 41L, 13L, 30L, 36L, 51L, 2L, 10L, 9L,
21L, 32L, 39L, 38L, 49L, 22L, 31L, 32L, 35L, 20L, 41L, 9L, 21L,
13L, 30L, 43L, 16L, 23L, 7L, 20L, 17L, 25L, 15L, 25L, 3L, 45L,
23L, 36L, 38L, 49L, 8L, 21L, 47L, 36L, 39L, 51L, 36L, 51L, 7L,
20L, 36L, 39L), .Label = c("AK", "AL", "AR", "AZ", "CA", "CO",
"CT", "DC", "DE", "FL", "GA", "HI", "IA", "ID", "IL", "IN", "KS",
"KY", "LA", "MA", "MD", "ME", "MI", "MN", "MO", "MS", "MT", "NC",
"ND", "NE", "NH", "NJ", "NM", "NV", "NY", "OH", "OK", "OR", "PA",
"PR", "RI", "SC", "SD", "TN", "TX", "UT", "VA", "VT", "WA", "WI",
"WV", "WY"), class = "factor"), Total.Interstate = c(689297,
2706436, 1717903, 490934, 130534, 317067, 885470, 50894, 32646738,
750415, 295058, 1102270, 0, 405983, 15280733, 968791, 906632,
2875733, 51046226, 5306520, 0, 4962678, 12658267, 0, 665400,
0, 800153, 472696, 0, 0, 1016139, 1046016, 0, 0, 0, 0, 449935,
37485, 250188, 795743, 366382, 0, 250129, 4158714, 525517, 0,
254649, 887141, 2187800, 0, 1240781, 0, 2331335, 0, 0, 92459,
1539373, 263465, 1603775, 0, 0, 1626514, 6888690, 11033320, 1052552,
0, 0, 346120, 0, 0, 0, 504359, 940662, 776776, 6294099, 210203,
0, 21739191, 0, 0, 0, 0, 885810, 0, 31682141, 25014832, 2886048,
0, 407582, 3363031, 0, 244028, 0, 1822942, 4081638, 665964, 5732895,
16018476, 8990522, 2081329, 224293, 1104744, 0, 3367518, 2958190,
5244668, 0, 0, 266650, 58654, 120131, 412832, 0, 1135819, 4217187,
0, 388515, 4979983, 22264838, 356893, 420020, 72195, 3896542,
0, 0, 1345355, 15662071, 16145014, 0, 0, 0, 607961, 712753, 425473,
6099553, 1558534, 32354), Total.OFE = c(18991, 2248965, 190948,
0, 0, 0, 1093957, 0, 11419457, 71861, 0, 0, 25174, 95089, 556051,
0, 0, 1234150, 1867285, 185095, 0, 29856, 1463447, 0, 0, 120315,
451504, 0, 0, 0, 0, 45556, 0, 713615, 0, 0, 17964, 53959, 0,
82757, 298458, 0, 0, 2732458, 0, 109290, 0, 0, 121637, 0, 38545,
0, 345698, 0, 0, 0, 0, 0, 0, 0, 452960, 22893, 2135114, 4340081,
155479, 34724, 0, 274535, 0, 6665, 0, 97324, 0, 443043, 1466411,
0, 0, 11028645, 0, 0, 514586, 0, 1520210, 0, 26365618, 36364009,
265284, 68995, 0, 2283375, 0, 0, 0, 0, 849261, 0, 5613574, 6723001,
2684766, 1312244, 13385, 1124456, 0, 1168943, 533528, 3310200,
0, 328648, 0, 80369, 0, 803930, 77071, 179135, 289219, 0, 129759,
528606, 4253305, 21492, 43455, 75043, 346366, 0, 140417, 1031357,
5436421, 6436357, 501657, 24393, 186054, 259871, 36741, 0, 560378,
1100184, 62414), Total.OPA = c(228312, 2982032, 2542741, 974397,
123570, 225424, 218533, 0, 25381617, 418212, 518696, 134505,
0, 260528, 6710354, 483376, 356619, 1772362, 38808070, 3718556,
0, 881091, 5388603, 66562, 1092771, 617521, 1408705, 251775,
0, 0, 783596, 668758, 0, 267956, 500603, 58701, 474685, 222117,
12546, 96320, 763818, 0, 89295, 4393273, 1402738, 373334, 165658,
546181, 2195543, 25128, 776787, 97761, 1174333, 0, 38597, 326568,
412703, 17398, 291002, 638902, 65204, 614783, 730596, 2607513,
758708, 147880, 59452, 727375, 93805, 44389, 74778, 305465, 116506,
905661, 6244804, 626238, 0, 6291811, 0, 384349, 3466289, 82685,
1222432, 0, 30837298, 28959580, 642784, 163171, 191105, 2427024,
188396, 478174, 123704, 2173713, 4053910, 531028, 7694299, 16843732,
6467851, 1364177, 25251, 255553, 0, 2205666, 780108, 4751762,
287803, 735025, 543414, 14782, 0, 680610, 221835, 418050, 2911193,
64895, 333266, 3028990, 7679700, 174700, 496528, 56500, 2581569,
81459, 126293, 2890433, 10291470, 11162953, 172943, 0, 218140,
113766, 406393, 119416, 2900666, 1381759, 188272), Total.Arterial..Minor. = c(157908,
2020372, 1770155, 636492, 70134, 0, 932828, 1022, 9502519, 458749,
17689, 190791, 0, 138749, 4532335, 378976, 661540, 517301, 29421302,
32684, 0, 1901119, 5827148, 17757, 0, 281950, 1258191, 0, 0,
30039, 0, 656022, 60879, 764644, 0, 3188, 651620, 9340, 4164,
526975, 0, 18974, 190500, 82205, 354159, 94178, 234930, 913998,
2772408, 0, 873458, 0, 1150458, 13621, 40913, 145707, 0, 0, 374237,
171769, 122735, 679810, 5253934, 5504799, 4520, 58291, 10769,
35338, 317108, 106138, 0, 267714, 225899, 870058, 425506, 47331,
16563, 19522722, 0, 1606, 1387615, 0, 1110317, 0, 20529277, 23492185,
947655, 31760, 8263, 1965052, 43218, 389765, 103565, 2880815,
1484034, 0, 5112579, 10216887, 6047024, 1094547, 81937, 545648,
138121, 2475470, 1342276, 1685899, 55253, 0, 0, 52849, 15493,
102073, 291979, 554982, 1885355, 10577, 264599, 2191720, 5898970,
168168, 0, 250859, 1649429, 7704, 164828, 1876335, 47124, 6033706,
113033, 0, 114701, 139601, 146651, 234444, 1626191, 1348222,
144966), duplicate.flag = c(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,
TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE)), class = c("tbl_df",
"tbl", "data.frame"), row.names = c(NA, -137L))
回答1:
SOLUTION:
From rlang::last_trace()
You can see the error is in line 27 in the package vctrs
These dots only exist to allow future extensions and should be empty.
Did you misspecify an argument?
Backtrace:
█
1. └─joineddf %>% select(Apportioned)
2. ├─base::withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
3. └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
4. └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
5. └─`_fseq`(`_lhs`)
6. └─magrittr::freduce(value, `_function_list`)
7. ├─base::withVisible(function_list[[k]](value))
8. └─function_list[[k]](value)
9. ├─dplyr::select(., Apportioned)
10. └─dplyr:::select.data.frame(., Apportioned)
11. └─tidyselect::vars_select(tbl_vars(.data), !!!enquos(...))
12. └─tidyselect:::eval_select_impl(...)
13. ├─tidyselect:::with_subscript_errors(...)
14. │ ├─base::tryCatch(...)
15. │ │ └─base:::tryCatchList(expr, classes, parentenv, handlers)
16. │ │ └─base:::tryCatchOne(expr, names, parentenv, handlers[[1L]])
17. │ │ └─base:::doTryCatch(return(expr), name, parentenv, handler)
18. │ └─tidyselect:::instrument_base_errors(expr)
19. │ └─base::withCallingHandlers(...)
20. └─tidyselect:::vars_select_eval(...)
21. └─tidyselect:::walk_data_tree(expr, data_mask, context_mask)
22. └─tidyselect:::eval_c(expr, data_mask, context_mask)
23. └─tidyselect:::reduce_sels(node, data_mask, context_mask, init = init)
24. └─tidyselect:::walk_data_tree(init, data_mask, context_mask)
25. └─tidyselect:::as_indices_sel_impl(...)
26. └─tidyselect:::as_indices_impl(x, vars, strict = strict)
27. └─vctrs::vec_as_subscript(x, logical = "error")
28. └─ellipsis::check_dots_empty()
29. └─ellipsis:::action_dots(...)
Tidyverse was installing a version of vctrs
0.2.99.99011 - a version I could not find anywhere on the web. What is causing this?
The solution is simply to manually install vctrs
before tidyverse
install.packages("vctrs")
library(vctrs)
来源:https://stackoverflow.com/questions/61599249/why-am-i-getting-the-is-not-empty-error-mostly-when-using-pipe-and-basic