codedthinking / Kezdi.jl

An umbrella of Julia packages for data analysis, in loving memory of Gábor Kézdi
Other
9 stars 0 forks source link

count #46

Closed korenmiklos closed 1 day ago

korenmiklos commented 2 days ago

No check for missing is needed. count and count if in Stata simply returns the number of rows, which would be nrow($target_df)

korenmiklos commented 2 days ago

Please see refactor at https://github.com/codedthinking/Kezdi.jl/commit/877e5cd46f58c8a642d2403a31ca4dd7a59d75dd#diff-24af1c45494294b929fb875e5f632a83e6b5fead1a8f9796551b1fb41a6a1533

I think it will be sufficient to call nrow($target_df) |> $teardown, no need for a separate function.

gergelyattilakiss commented 1 day ago

Still had to add functions for @count as 2 types are passed in because of by() option one is DataFrame the other is GroupedDataFrame