trinker / sentimentr

Dictionary based sentiment analysis that considers valence shifters
Other
427 stars 84 forks source link

combine_data not working for cannon data set #94

Closed trinker closed 6 years ago

trinker commented 6 years ago

This works:

dats <- c( 
    "crowdflower_deflategate", 
    "crowdflower_products", 
    "course_evaluations", 
    "crowdflower_self_driving_cars", 
    "crowdflower_weather", 
    "hotel_reviews", 
    "kaggle_movie_reviews", 
    "cannon_reviews", 
    "kotzias_reviews_amazon_cells"
) 

cdat <- combine_data(dats[c(1:7, 9)])

This does not

cdat <- combine_data(dats[c(1:8)])
Error in data.table::rbindlist(dats) : 
  Item 8 has 4 columns, inconsistent with item 1 which has 3 columns. If instead you need to fill missing columns, use set argument 'fill' to TRUE

Is the fix as easy as using fill = TRUE? What's causing the issue to begin with (the extra column of number? Should cannon_reviews$number be removed?

trinker commented 6 years ago

number is not documented so it looks like this should be removed.