How to sum by column:
Use “sum” to sum by column. Example: sum(datafame$column, na.rm=true)
Subsetting
small <- subset(original, select=c(weight, Time), subset=(Diet==4 && Time > 20))
References
- Sum
- Pivot Table: https://cran.r-project.org/web/packages/pivottabler/vignettes/v00-vignettes.html
- Unique value: https://stat.ethz.ch/R-manual/R-devel/library/base/html/unique.html
- Data analysis functions: https://cran.r-project.org/web/packages/Hmisc/Hmisc.pdf
- Summarytools: https://cran.r-project.org/web/packages/summarytools/summarytools.pdf