OpenIntroStat / oilabs

🛑 This package has been deprecated and datasets and functionality have been moved to the openintro package
https://github.com/OpenIntroStat/openintro
Creative Commons Zero v1.0 Universal
10 stars 19 forks source link

calc_streak() doesn't actually take a data.frame #33

Closed beanumber closed 6 years ago

beanumber commented 8 years ago

The Help for calc_streak() says:

x A data frame or character vector of hits ("H") and misses ("M").

But it won't actually work with a data frame argument.

kobe_basket %>% select(shot) %>% calc_streak()
Error in calc_streak(.) : 
  Input should only contain hits ("H") and misses ("M")

Could it?

mine-cetinkaya-rundel commented 7 years ago

It could, but actually in the lab we have it use the $ operator, so it doesn't need to. Since it's a one off function just used in this lab, I am not sure if it's worth it to update, but let me know if you disagree.

mine-cetinkaya-rundel commented 6 years ago

Looks like this was already addressed in f2181f4fa15b689c26aeb60f7fbc7e8f1d625858, just never closed. Doing so now.