Describe the bug
The scale for Dale-Chall readability is wrong. It should be ranged from 0 to 10 and should not be negative.
Reproducible code
library(quanteda)
dale.chall<-textstat_readability("The scale for Dale-Chall readability is wrong. It should be ranged from 0 to 10 and should not be negative",measure = c("Dale.Chall"))
Expected behavior
document Dale.Chall
1 text1 -38.245
Please explain what you expected to happen.
The score should be positive and lie in the range of [0,10]
## System information
Please run sessionInfo() and paste the output.
R version 3.4.4 (2018-03-15)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Sierra 10.12.6
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] parallel stats graphics grDevices utils datasets methods base
other attached packages:
[1] koRpus_0.10-2 data.table_1.11.4 quanteda_1.3.4 doParallel_1.0.11
[5] iterators_1.0.10 foreach_1.4.4 lubridate_1.7.4 rlist_0.4.6.1
[9] jsonlite_1.5 rcompanion_1.13.2 moments_0.14 MASS_7.3-50
[13] pequod_0.0-5 car_3.0-0 carData_3.0-1 sentimentr_2.3.2
[17] bindrcpp_0.2.2 jtools_1.0.0 ggplot2_3.0.0 sjmisc_2.7.3
[21] sjPlot_2.5.0 psych_1.8.4 magrittr_1.5 dplyr_0.7.6
loaded via a namespace (and not attached):
[1] readxl_1.0.0 backports_1.1.2 fastmatch_1.1-0
[4] miscTools_0.6-22 BSDA_1.2.0 plyr_1.8.4
[7] lazyeval_0.2.1 TMB_1.7.14 splines_3.4.4
[10] TH.data_1.0-9 digest_0.6.15 htmltools_0.3.6
[13] fansi_0.2.3 cluster_2.0.6 openxlsx_4.1.0
[16] modelr_0.1.2 RcppParallel_4.4.1 textshape_1.6.0
[19] sandwich_2.4-0 colorspace_1.3-2 haven_1.1.2
[22] crayon_1.3.4 lme4_1.1-17 bindr_0.1.1
[25] survival_2.41-3 zoo_1.8-3 glue_1.3.0
[28] stopwords_0.9.0 gtable_0.2.0 emmeans_1.2.3
[31] sjstats_0.16.0 spacyr_0.9.91 maxLik_1.3-4
[34] mlapi_0.1.0 abind_1.4-5 scales_0.5.0
[37] futile.options_1.0.1 mvtnorm_1.0-8 qdapRegex_0.7.2
[40] ggeffects_0.4.0 Rcpp_0.12.18 xtable_1.8-2
[43] foreign_0.8-69 text2vec_0.5.1 textclean_0.9.3
[46] stats4_3.4.4 prediction_0.3.6 survey_3.33-2
[49] RColorBrewer_1.1-2 modeltools_0.2-22 pkgconfig_2.0.1
[52] reshape_0.8.7 manipulate_1.0.1 nnet_7.3-12
[55] multcompView_0.1-7 utf8_1.1.4 tidyselect_0.2.4
[58] labeling_0.3 rlang_0.2.1 munsell_0.5.0
[61] cellranger_1.1.0 tools_3.4.4 cli_1.0.0
[64] ade4_1.7-11 sjlabelled_1.0.12 broom_0.5.0
[67] ggridges_0.5.0 evaluate_0.11 EMT_1.1
[70] stringr_1.3.1 arm_1.10-1 knitr_1.20
[73] zip_1.0.0 RVAideMemoire_0.9-69-3 purrr_0.2.5
[76] coin_1.2-2 WRS2_0.10-0 nlme_3.1-131.1
[79] formatR_1.5 compiler_3.4.4 bayesplot_1.5.0
[82] rstudioapi_0.7 curl_3.2 e1071_1.6-8
[85] syuzhet_1.0.4 tibble_1.4.2 DescTools_0.99.24
[88] stringi_1.2.4 hermite_1.1.2 futile.logger_1.4.3
[91] forcats_0.3.0 lattice_0.20-35 Matrix_1.2-12
[94] nloptr_1.0.4 vegan_2.5-2 permute_0.9-4
[97] effects_4.0-2 stringdist_0.9.5.1 pillar_1.3.0
[100] mc2d_0.1-18 pwr_1.2-2 lmtest_0.9-36
[103] ucminf_1.1-4 estimability_1.3 R6_2.2.2
[106] ordinal_2018.4-19 rio_0.5.10 lexicon_1.0.0
[109] codetools_0.2-15 lambda.r_1.2.3 boot_1.3-20
[112] assertthat_0.2.0 rprojroot_1.3-2 withr_2.1.2
[115] nortest_1.0-4 mnormt_1.5-5 multcomp_1.4-8
[118] mgcv_1.8-23 expm_0.999-2 hms_0.4.2
[121] grid_3.4.4 tidyr_0.8.1 coda_0.19-1
[124] glmmTMB_0.2.2.0 class_7.3-14 minqa_1.2.4
[127] rmarkdown_1.10 snakecase_0.9.1 pbdZMQ_0.3-3 ```
## Additional info
Please add any other information about the issue.
Describe the bug
The scale for Dale-Chall readability is wrong. It should be ranged from 0 to 10 and should not be negative.
Reproducible code
Expected behavior
document Dale.Chall
1 text1 -38.245
Please explain what you expected to happen.
The score should be positive and lie in the range of [0,10]
## System information
Please run
sessionInfo()and paste the output.