cr.cube 3.0.45__tar.gz → 3.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (486) hide show
  1. {cr.cube-3.0.45 → cr.cube-3.1.0}/PKG-INFO +4 -1
  2. {cr.cube-3.0.45 → cr.cube-3.1.0}/README.md +3 -0
  3. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/__init__.py +1 -1
  4. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/matrix/measure.py +59 -17
  5. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/matrix/subtotals.py +131 -0
  6. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/stripe/insertion.py +62 -0
  7. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/stripe/measure.py +8 -1
  8. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/PKG-INFO +4 -1
  9. cr.cube-3.1.0/tests/fixtures/cat-date.json +315 -0
  10. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_cubepart.py +2 -2
  11. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_headers_and_subtotals.py +372 -0
  12. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/matrix/test_measure.py +6 -0
  13. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/stripe/test_measure.py +8 -1
  14. {cr.cube-3.0.45 → cr.cube-3.1.0}/tox.ini +1 -1
  15. cr.cube-3.0.45/tests/fixtures/cat-date.json +0 -154
  16. {cr.cube-3.0.45 → cr.cube-3.1.0}/.coveragerc +0 -0
  17. {cr.cube-3.0.45 → cr.cube-3.1.0}/.flake8 +0 -0
  18. {cr.cube-3.0.45 → cr.cube-3.1.0}/.pre-commit-config.yaml +0 -0
  19. {cr.cube-3.0.45 → cr.cube-3.1.0}/.readthedocs.yaml +0 -0
  20. {cr.cube-3.0.45 → cr.cube-3.1.0}/HISTORY.md +0 -0
  21. {cr.cube-3.0.45 → cr.cube-3.1.0}/LICENSE +0 -0
  22. {cr.cube-3.0.45 → cr.cube-3.1.0}/MANIFEST.in +0 -0
  23. {cr.cube-3.0.45 → cr.cube-3.1.0}/Makefile +0 -0
  24. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/Makefile +0 -0
  25. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/Makefile +0 -0
  26. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/conf.py +0 -0
  27. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/crunch_logo.png +0 -0
  28. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/cube.rst +0 -0
  29. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/cubepart.rst +0 -0
  30. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/dimension.rst +0 -0
  31. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/index.rst +0 -0
  32. {cr.cube-3.0.45 → cr.cube-3.1.0}/docs/source/quickstart.rst +0 -0
  33. {cr.cube-3.0.45 → cr.cube-3.1.0}/requirements-rtd.txt +0 -0
  34. {cr.cube-3.0.45 → cr.cube-3.1.0}/setup.cfg +0 -0
  35. {cr.cube-3.0.45 → cr.cube-3.1.0}/setup.py +0 -0
  36. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/__init__.py +0 -0
  37. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/collator.py +0 -0
  38. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/cube.py +0 -0
  39. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/cubepart.py +0 -0
  40. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/dimension.py +0 -0
  41. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/enums.py +0 -0
  42. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/matrix/__init__.py +0 -0
  43. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/matrix/assembler.py +0 -0
  44. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/matrix/cubemeasure.py +0 -0
  45. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/measures/__init__.py +0 -0
  46. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/measures/pairwise_significance.py +0 -0
  47. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/min_base_size_mask.py +0 -0
  48. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/scalar.py +0 -0
  49. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/smoothing.py +0 -0
  50. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/stripe/__init__.py +0 -0
  51. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/stripe/assembler.py +0 -0
  52. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/stripe/cubemeasure.py +0 -0
  53. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr/cube/util.py +0 -0
  54. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/SOURCES.txt +0 -0
  55. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/dependency_links.txt +0 -0
  56. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/namespace_packages.txt +0 -0
  57. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/requires.txt +0 -0
  58. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/top_level.txt +0 -0
  59. {cr.cube-3.0.45 → cr.cube-3.1.0}/src/cr.cube.egg-info/zip-safe +0 -0
  60. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/__init__.py +0 -0
  61. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/admit-x-dept-unweighted-col-prop-moe.py +0 -0
  62. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-subvar-ca-cat-x-cat-date-scale-means-w2.py +0 -0
  63. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-subvar-x-ca-cat-cat-date-smoothed-col-idx-w3.py +0 -0
  64. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-subvar-x-ca-cat-cat-date-smoothed-col-pct-w3.py +0 -0
  65. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-subvar-x-ca-cat-hs-pw-pvals.py +0 -0
  66. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-subvar-x-ca-cat-hs-pw-tstats.py +0 -0
  67. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-x-cat-hs-explicit-order.py +0 -0
  68. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/ca-x-mr-explicit-order.py +0 -0
  69. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-subdiff-x-cat-pw-pvals.py +0 -0
  70. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-subdiff-x-cat-pw-tstats.py +0 -0
  71. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-cat-date-smoothed-col-idx-w3.py +0 -0
  72. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-cat-date-smoothed-col-pct-w3.py +0 -0
  73. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-col-moe.py +0 -0
  74. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-col-stddev.py +0 -0
  75. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-col-stderr.py +0 -0
  76. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-column-proportions.py +0 -0
  77. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-columns-margin-proportions.py +0 -0
  78. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-pvals.py +0 -0
  79. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-pw-idxs.py +0 -0
  80. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-row-margin-proportions.py +0 -0
  81. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-row-proportions.py +0 -0
  82. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-tbl-stddev.py +0 -0
  83. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-tbl-stderr.py +0 -0
  84. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-hs-x-mr-zscores.py +0 -0
  85. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-col-idx-explicit-order.py +0 -0
  86. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-col-props-moe.py +0 -0
  87. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-date-smoothed-col-pct-w1.py +0 -0
  88. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-date-smoothed-scale-means-w2.py +0 -0
  89. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-date-wgtd-smoothed-col-idx-w4.py +0 -0
  90. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-date-wgtd-smoothed-col-pct-w4.py +0 -0
  91. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-explicit-order.py +0 -0
  92. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-pw-idxs-alt.py +0 -0
  93. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-pw-idxs.py +0 -0
  94. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-pw-pvals.py +0 -0
  95. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-pw-tstats.py +0 -0
  96. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-scale-mean-pw-idxs-alt.py +0 -0
  97. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-scale-mean-pw-idxs.py +0 -0
  98. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-scale-means-pw-pvals.py +0 -0
  99. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-hs-scale-means-pw-tstats.py +0 -0
  100. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-population-counts-moe.py +0 -0
  101. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-population-counts.py +0 -0
  102. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pruning-hs-col-prop-moe.py +0 -0
  103. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pruning-hs-table-prop-moe.py +0 -0
  104. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pw-idxs-recip.py +0 -0
  105. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pw-idxs.py +0 -0
  106. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pw-pvals.py +0 -0
  107. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-pw-tstats.py +0 -0
  108. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-scale-mean-pw-idxs-alt.py +0 -0
  109. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-scale-mean-pw-idxs.py +0 -0
  110. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-ucounts-explicit-order.py +0 -0
  111. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-wgtd-pw-indices.py +0 -0
  112. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-wgtd-pw-pvals.py +0 -0
  113. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-wgtd-pw-tstats.py +0 -0
  114. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-cat-zscores-explicit-order.py +0 -0
  115. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-explicit-order.py +0 -0
  116. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-pw-idxs.py +0 -0
  117. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-scale-mean-pw-idxs-alt.py +0 -0
  118. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-scale-mean-pw-idxs.py +0 -0
  119. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-x-cat-date-smoothed-col-idx-w3.py +0 -0
  120. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat-x-mr-x-cat-date-smoothed-col-pct-w3.py +0 -0
  121. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat_x_cat_hirotsu_chi_squared.txt +0 -0
  122. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat_x_cat_hirotsu_pvals.txt +0 -0
  123. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/cat_x_cat_with_hs_hirotsu_pvals.txt +0 -0
  124. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/col-per-moe-cat-x-cat-hs-2rows-1col.py +0 -0
  125. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/col-std-dev-cat-x-cat-hs-2rows-1col.py +0 -0
  126. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/col-std-err-cat-x-cat-hs-2rows-1col.py +0 -0
  127. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/datetime-x-cat-date-smoothed-col-idx-w3.py +0 -0
  128. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/datetime-x-cat-date-smoothed-col-pct-w3.py +0 -0
  129. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/econ-gender-x-ideology-weighted-col-prop-moe.py +0 -0
  130. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/econ-gender-x-ideology-weighted-row-prop-moe.py +0 -0
  131. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/econ-gender-x-ideology-weighted-row-std-dev.py +0 -0
  132. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/econ-gender-x-ideology-weighted-table-prop-moe.py +0 -0
  133. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-date-smoothed-col-idx-w3.py +0 -0
  134. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-date-smoothed-col-pct-w3.py +0 -0
  135. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-explicit-order.py +0 -0
  136. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-col-moe.py +0 -0
  137. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-col-stddev.py +0 -0
  138. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-col-stderr.py +0 -0
  139. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-column-proportions.py +0 -0
  140. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-columns-margin-proportions.py +0 -0
  141. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-explicit-order.py +0 -0
  142. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-pvals.py +0 -0
  143. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-pw-idxs.py +0 -0
  144. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-row-margin-proportions.py +0 -0
  145. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-row-proportions.py +0 -0
  146. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-tbl-stddev.py +0 -0
  147. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-tbl-stderr.py +0 -0
  148. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-hs-zscores.py +0 -0
  149. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-pw-idxs-alt.py +0 -0
  150. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-pw-idxs.py +0 -0
  151. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-col-moe.py +0 -0
  152. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-col-std-dev.py +0 -0
  153. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-col-std-err.py +0 -0
  154. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-table-moe.py +0 -0
  155. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-table-std-dev.py +0 -0
  156. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-table-std-err.py +0 -0
  157. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-cat-weighted-zscores.py +0 -0
  158. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-column-proportions.py +0 -0
  159. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-columns-margin-proportions.py +0 -0
  160. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-explicit-order.py +0 -0
  161. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-pw-idxs.py +0 -0
  162. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-pw-pvals.py +0 -0
  163. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-pw-tstats.py +0 -0
  164. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-row-margin-proportions.py +0 -0
  165. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr-x-mr-row-proportions.py +0 -0
  166. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr_x_cat_chi_squared_rows.txt +0 -0
  167. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/mr_x_cat_pairwise_pvals.txt +0 -0
  168. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/num-arr-means-grouped-by-cat-hs-p-vals-col-7.py +0 -0
  169. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/num-arr-means-grouped-by-cat-hs-t-stats-col-7.py +0 -0
  170. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/num-arr-means-grouped-by-cat-p-vals-col-4.py +0 -0
  171. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/num-arr-means-grouped-by-cat-t-stats-col-4.py +0 -0
  172. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/num-array-means-grouped-by-cat-date-smoothed.py +0 -0
  173. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/numeric-x-cat-date-smoothed-col-idx-w3.py +0 -0
  174. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/numeric-x-cat-date-smoothed-col-pct-w3.py +0 -0
  175. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/txt-x-cat-date-smoothed-col-idx-w3.py +0 -0
  176. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/expectations/txt-x-cat-date-smoothed-col-pct-w3.py +0 -0
  177. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/__init__.py +0 -0
  178. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/admit-x-dept-unweighted.json +0 -0
  179. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/admit-x-gender-weighted.json +0 -0
  180. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/age-x-accrpipe.json +0 -0
  181. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-as-0th.json +0 -0
  182. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-cat-x-ca-subvar.json +0 -0
  183. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-cat-x-mr-x-ca-subvar-hs.json +0 -0
  184. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-food-groups-x-shape-of-pasta-with-insertions.json +0 -0
  185. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-items-x-ca-cat-x-cat.json +0 -0
  186. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-single-cat.json +0 -0
  187. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subdiff.json +0 -0
  188. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-hs-x-mr-x-ca-cat.json +0 -0
  189. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-hs-x-mr.json +0 -0
  190. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-x-ca-cat-empties.json +0 -0
  191. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-x-ca-cat-hs.json +0 -0
  192. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-x-ca-cat-mean.json +0 -0
  193. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-x-ca-cat-x-cat-date.json +0 -0
  194. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-subvar-x-ca-cat-x-mr.json +0 -0
  195. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-with-nets.json +0 -0
  196. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-cat-hs.json +0 -0
  197. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-mr-hs.json +0 -0
  198. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-mr-sig-testing-subtotals.json +0 -0
  199. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-mr-weighted-hs.json +0 -0
  200. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-mr.json +0 -0
  201. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/ca-x-single-cat.json +0 -0
  202. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-4-x-cat-4.json +0 -0
  203. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-4-x-cat-5.json +0 -0
  204. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-date-mean.json +0 -0
  205. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-date-x-cat.json +0 -0
  206. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-mt-x-cat-hs-mt.json +0 -0
  207. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-mt.json +0 -0
  208. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-subdiff-x-cat.json +0 -0
  209. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-cat-date.json +0 -0
  210. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-cat-hs-empties.json +0 -0
  211. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-cat-hs.json +0 -0
  212. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-cat.json +0 -0
  213. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-mr-wgtd.json +0 -0
  214. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-hs-x-mr.json +0 -0
  215. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-mean.json +0 -0
  216. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-means-and-counts.json +0 -0
  217. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-means-hs.json +0 -0
  218. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-median.json +0 -0
  219. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-stddev.json +0 -0
  220. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-subtot-order.json +0 -0
  221. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-sum-x-mr.json +0 -0
  222. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-sum.json +0 -0
  223. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-all-missing-row-elements.json +0 -0
  224. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-date-wgtd.json +0 -0
  225. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-date.json +0 -0
  226. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-filt-complete.json +0 -0
  227. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-filt.json +0 -0
  228. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-german-weighted.json +0 -0
  229. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-hs-2rows-1col.json +0 -0
  230. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-hs-missing.json +0 -0
  231. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-hs-total-bottom.json +0 -0
  232. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-hs.json +0 -0
  233. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-mean-subtot.json +0 -0
  234. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-mean-wgtd.json +0 -0
  235. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-weighted-ttests.json +0 -0
  236. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-wgtd.json +0 -0
  237. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-with-empty-cols.json +0 -0
  238. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-x-cat-wgtd-no-query-weight.json +0 -0
  239. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat-x-cat-wgtd.json +0 -0
  240. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-cat.json +0 -0
  241. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-date-hs-prune.json +0 -0
  242. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-datetime.json +0 -0
  243. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-items-x-cats-hs.json +0 -0
  244. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-logical.json +0 -0
  245. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-2.json +0 -0
  246. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-pruned-col.json +0 -0
  247. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-pruned-row-col.json +0 -0
  248. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-pruned-row.json +0 -0
  249. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-sentry.json +0 -0
  250. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-stddev.json +0 -0
  251. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-subvar-means.json +0 -0
  252. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-unicode-sv-alias.json +0 -0
  253. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-weighted-hs.json +0 -0
  254. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-cat-date.json +0 -0
  255. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-cat-missing.json +0 -0
  256. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-cat.json +0 -0
  257. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-mr-empty-cols.json +0 -0
  258. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-mr-pruned-rows.json +0 -0
  259. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr-x-mr.json +0 -0
  260. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-mr.json +0 -0
  261. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-num-hs-prune.json +0 -0
  262. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat-x-num-x-datetime.json +0 -0
  263. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/cat.json +0 -0
  264. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/countries-x-shapes-of-pasta.json +0 -0
  265. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/date.json +0 -0
  266. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/datetime-x-cat-date.json +0 -0
  267. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/deck-with-mean.json +0 -0
  268. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/dichotomized-numeric-mean.json +0 -0
  269. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/direction-of-country-x-education-weighted.json +0 -0
  270. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-blame-with-hs.json +0 -0
  271. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-blame-x-ideology-col-hs.json +0 -0
  272. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-blame-x-ideology-row-and-col-hs.json +0 -0
  273. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-blame-x-ideology-row-hs.json +0 -0
  274. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-gender-x-ideology-weighted.json +0 -0
  275. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-mean-age-blame-x-gender.json +0 -0
  276. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-mean-no-dims.json +0 -0
  277. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-nodata-no-dims.json +0 -0
  278. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/econ-us-problem-x-bigger-problem.json +0 -0
  279. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/edu-fav5.json +0 -0
  280. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/food-groops-x-starttime-x-nordic-countries.json +0 -0
  281. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/food-group-x-shape-of-pasta-2rows-insertion.json +0 -0
  282. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/food-group-x-shape-pasta-2rows1col-insertion.json +0 -0
  283. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-hs-top-bottom.json +0 -0
  284. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-x-pets-array-pets-first.json +0 -0
  285. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-x-pets-array-subvars-first.json +0 -0
  286. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-x-pets-array.json +0 -0
  287. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-x-pets-hs-top-bottom.json +0 -0
  288. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/fruit-x-pets.json +0 -0
  289. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/full-cube.json +0 -0
  290. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/gender-party-race.json +0 -0
  291. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/gender-x-weight.json +0 -0
  292. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/huffpost-actions-x-household.json +0 -0
  293. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/letters-x-pets-hs.json +0 -0
  294. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/logical-univariate.json +0 -0
  295. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mean-cat-x-cat.json +0 -0
  296. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-3d.json +0 -0
  297. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-cat-hs-x-cat-hs.json +0 -0
  298. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-cat-x-cat-hs.json +0 -0
  299. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-cat-x-mr-2.json +0 -0
  300. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-cat-x-mr.json +0 -0
  301. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/means-mr-x-cat.json +0 -0
  302. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/median-cat-x-cat-hs.json +0 -0
  303. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/median-cat-x-mr.json +0 -0
  304. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/median-mr-x-cat.json +0 -0
  305. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/missing-cat-hs.json +0 -0
  306. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-1-x-mr-3.json +0 -0
  307. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-mean-filt-wgtd.json +0 -0
  308. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-mean-weighted.json +0 -0
  309. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-mean.json +0 -0
  310. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-median.json +0 -0
  311. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-stddev.json +0 -0
  312. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-sum.json +0 -0
  313. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-wgtd.json +0 -0
  314. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-ca-cat-x-ca-subvar.json +0 -0
  315. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-ca-hs.json +0 -0
  316. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-2.json +0 -0
  317. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-both-single-element.json +0 -0
  318. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-date.json +0 -0
  319. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-hs-mt.json +0 -0
  320. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-mean-weighted.json +0 -0
  321. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-mean.json +0 -0
  322. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-not-so-simple-alltypes.json +0 -0
  323. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-profiles-stats-weighted.json +0 -0
  324. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-pruned-col.json +0 -0
  325. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-pruned-row-col.json +0 -0
  326. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-pruned-row.json +0 -0
  327. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-with-means.json +0 -0
  328. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-x-mr-prune.json +0 -0
  329. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat-x-mr.json +0 -0
  330. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-cat.json +0 -0
  331. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-2.json +0 -0
  332. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-index-table.json +0 -0
  333. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-mean-weighted.json +0 -0
  334. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-mean.json +0 -0
  335. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-means.json +0 -0
  336. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-median.json +0 -0
  337. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-selected-categories.json +0 -0
  338. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-single-cat.json +0 -0
  339. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-sum.json +0 -0
  340. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-with-pruning.json +0 -0
  341. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr-x-cat.json +0 -0
  342. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-mr.json +0 -0
  343. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-other-mr.json +0 -0
  344. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr-x-single-wave.json +0 -0
  345. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/cat-hs-top-btm.json +0 -0
  346. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/cat-x-mr-hs.json +0 -0
  347. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/cat-x-mr.json +0 -0
  348. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/mr-x-cat.json +0 -0
  349. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/mr-x-mr.json +0 -0
  350. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/scorecard.json +0 -0
  351. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/mr_insertions/univariate-mr.json +0 -0
  352. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/not-mr-cats.json +0 -0
  353. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/nssat-mr-x-3vl.json +0 -0
  354. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/nssat-mr-x-mr.json +0 -0
  355. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/num-binned.json +0 -0
  356. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/num-x-num-empty.json +0 -0
  357. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/num.json +0 -0
  358. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric-measures-x-cat.json +0 -0
  359. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric-x-cat-date.json +0 -0
  360. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-cat-date.json +0 -0
  361. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-cat-hs-weighted.json +0 -0
  362. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-cat-hs.json +0 -0
  363. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-cat-weighted.json +0 -0
  364. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-cat.json +0 -0
  365. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-grouped-by-date.json +0 -0
  366. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-no-grouping-weighted.json +0 -0
  367. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-no-grouping.json +0 -0
  368. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-scale-measures.json +0 -0
  369. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-x-mr-weighted.json +0 -0
  370. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-means-x-mr.json +0 -0
  371. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-median-grouped-by-cat.json +0 -0
  372. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-median-no-grouping.json +0 -0
  373. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-median-x-mr.json +0 -0
  374. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-multi-numeric-measures-grouped-by-cat.json +0 -0
  375. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-multi-numeric-measures-x-mr.json +0 -0
  376. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-stddev-grouped-by-cat.json +0 -0
  377. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-stddev-no-grouping.json +0 -0
  378. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-stddev-x-mr.json +0 -0
  379. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-sum-grouped-by-cat-hs.json +0 -0
  380. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-sum-grouped-by-cat.json +0 -0
  381. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-sum-no-grouping.json +0 -0
  382. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-sum-x-mr.json +0 -0
  383. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/numeric_arrays/num-arr-sums-with-nan-values.json +0 -0
  384. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/om-sgp8334215-vn-2019-sep-19-strand.json +0 -0
  385. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/om-sgp8334215-vn-2019-sep-19.json +0 -0
  386. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/ca-sub-x-ca-cat-x-mr-sub-x-mr-sel.json +0 -0
  387. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-hs-x-mr.json +0 -0
  388. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-simple-x-mr.json +0 -0
  389. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-st-x-mr.json +0 -0
  390. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-x-mr-gender-x-all-pets-owned.json +0 -0
  391. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-x-mr-realistic-example.json +0 -0
  392. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/cat-x-mr-sub-x-mr-sel.json +0 -0
  393. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/mr-single-subvar-x-mr.json +0 -0
  394. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/mr-x-mr-realistic-example.json +0 -0
  395. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/overlaps/mr-x-mr.json +0 -0
  396. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-4x4.json +0 -0
  397. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-hirotsu-illness-x-occupation-plain-weights.json +0 -0
  398. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-hirotsu-illness-x-occupation-square-weights.json +0 -0
  399. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-hirotsu-illness-x-occupation-with-hs.json +0 -0
  400. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-hirotsu-illness-x-occupation.json +0 -0
  401. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-hirotsu-occupation-x-illness.json +0 -0
  402. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-random-3x4.json +0 -0
  403. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pairwise-with-zero-margin.json +0 -0
  404. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-array-cat-first.json +0 -0
  405. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-array-subvar-first.json +0 -0
  406. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-array-x-pets.json +0 -0
  407. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-array.json +0 -0
  408. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-x-fruit-hs.json +0 -0
  409. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-x-fruit.json +0 -0
  410. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-x-pets-array.json +0 -0
  411. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/pets-x-pets.json +0 -0
  412. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/profiles-percents.json +0 -0
  413. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/prompted-awareness.json +0 -0
  414. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/same-counts-3x4.json +0 -0
  415. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale-with-null-values.json +0 -0
  416. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/bolshevik-hair.json +0 -0
  417. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/ca-cat-x-items.json +0 -0
  418. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/ca-items-x-cat.json +0 -0
  419. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/ca-x-mr.json +0 -0
  420. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-nps-numval-x-cat.json +0 -0
  421. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-single-element-x-cat.json +0 -0
  422. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-x-ca-cat-x-items.json +0 -0
  423. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-x-cat-sm-margin.json +0 -0
  424. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-x-cat.json +0 -0
  425. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/cat-x-mr.json +0 -0
  426. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/mr-x-cat.json +0 -0
  427. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/univariate-ca-subvar.json +0 -0
  428. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/univariate-cat-with-all-null-numeric-value.json +0 -0
  429. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/univariate-cat-with-null-numeric-value.json +0 -0
  430. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scale_means/univariate-cat.json +0 -0
  431. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/scorecard.json +0 -0
  432. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/selected-3way-2-filledmissing.json +0 -0
  433. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/selected-3way-filledmissing.json +0 -0
  434. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/selected-crosstab-array-first.json +0 -0
  435. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/selected-crosstab-array-last.json +0 -0
  436. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/simple-ca-hs.json +0 -0
  437. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/simple-cat-array.json +0 -0
  438. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/simple-mr.json +0 -0
  439. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/single-col-margin-not-iterable.json +0 -0
  440. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/squared-weights-cat-x-cat.json +0 -0
  441. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/squared-weights.json +0 -0
  442. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/starttime-x-nordic-countries-x-food-groops.json +0 -0
  443. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/stats-test.json +0 -0
  444. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/sum-cat-x-mr.json +0 -0
  445. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/sum-mr-x-cat.json +0 -0
  446. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/test-dashboard-fixture.json +0 -0
  447. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/text.json +0 -0
  448. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/transforms/generic-transforms-dicts.json +0 -0
  449. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/transforms/test-dashboard-transform-no-ordering.json +0 -0
  450. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/transforms/test-dashboard-transform-single-el-visible.json +0 -0
  451. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/txt-x-cat-date.json +0 -0
  452. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/univ-mr-with-hs.json +0 -0
  453. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/univariate-categorical.json +0 -0
  454. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/fixtures/xyz-simple-alltypes.json +0 -0
  455. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/__init__.py +0 -0
  456. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_collator.py +0 -0
  457. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_cube.py +0 -0
  458. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_dimension.py +0 -0
  459. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_index_table.py +0 -0
  460. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_matrix.py +0 -0
  461. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_multiple_response.py +0 -0
  462. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_numeric_array.py +0 -0
  463. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_pairwise_significance.py +0 -0
  464. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_scale_additional_measures.py +0 -0
  465. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_scale_means.py +0 -0
  466. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_smoothing.py +0 -0
  467. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/integration/test_stripe.py +0 -0
  468. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/__init__.py +0 -0
  469. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/matrix/__init__.py +0 -0
  470. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/matrix/test_assembler.py +0 -0
  471. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/matrix/test_cubemeasure.py +0 -0
  472. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/matrix/test_subtotals.py +0 -0
  473. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/stripe/__init__.py +0 -0
  474. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/stripe/test_assembler.py +0 -0
  475. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/stripe/test_cubemeasure.py +0 -0
  476. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/stripe/test_insertion.py +0 -0
  477. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_collator.py +0 -0
  478. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_cube.py +0 -0
  479. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_cubepart.py +0 -0
  480. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_dimension.py +0 -0
  481. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_enum.py +0 -0
  482. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_scalar.py +0 -0
  483. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_smoothing.py +0 -0
  484. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unit/test_util.py +0 -0
  485. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/unitutil.py +0 -0
  486. {cr.cube-3.0.45 → cr.cube-3.1.0}/tests/util.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: cr.cube
3
- Version: 3.0.45
3
+ Version: 3.1.0
4
4
  Summary: Crunch.io Cube library
5
5
  Home-page: https://github.com/Crunch-io/crunch-cube/
6
6
  Author: Crunch.io
@@ -118,6 +118,9 @@ Description: # crunch-cube
118
118
 
119
119
  ## Changes
120
120
 
121
+ ### 3.1.0
122
+ - Subtotal diff (wave difference) for categorical date dimensions
123
+
121
124
  ### 3.0.45
122
125
  - Enumerator refactoring
123
126
 
@@ -110,6 +110,9 @@ The detailed description can be found
110
110
 
111
111
  ## Changes
112
112
 
113
+ ### 3.1.0
114
+ - Subtotal diff (wave difference) for categorical date dimensions
115
+
113
116
  ### 3.0.45
114
117
  - Enumerator refactoring
115
118
 
@@ -2,4 +2,4 @@
2
2
 
3
3
  """Initialization module for crunch-cube package."""
4
4
 
5
- __version__ = "3.0.45"
5
+ __version__ = "3.1.0"
@@ -13,6 +13,7 @@ from cr.cube.matrix.subtotals import (
13
13
  OverlapSubtotals,
14
14
  PositiveTermSubtotals,
15
15
  SumSubtotals,
16
+ WaveDiffSubtotal,
16
17
  )
17
18
  from cr.cube.smoothing import Smoother
18
19
  from cr.cube.util import lazyproperty
@@ -799,7 +800,13 @@ class _ColumnProportions(_BaseSecondOrderMeasure):
799
800
  """
800
801
  # --- do not propagate divide-by-zero warnings to stderr ---
801
802
  with np.errstate(divide="ignore", invalid="ignore"):
802
- return self._count_blocks[0][1] / self._weighted_base_blocks[0][1]
803
+ default_value = self._count_blocks[0][1] / self._weighted_base_blocks[0][1]
804
+ return WaveDiffSubtotal.subtotal_columns(
805
+ self._weighted_cube_counts.column_bases,
806
+ self._weighted_cube_counts.counts,
807
+ default_value,
808
+ self._dimensions,
809
+ )
803
810
 
804
811
  @lazyproperty
805
812
  def _subtotal_rows(self):
@@ -809,7 +816,13 @@ class _ColumnProportions(_BaseSecondOrderMeasure):
809
816
  """
810
817
  # --- do not propagate divide-by-zero warnings to stderr ---
811
818
  with np.errstate(divide="ignore", invalid="ignore"):
812
- return self._count_blocks[1][0] / self._weighted_base_blocks[1][0]
819
+ default_value = self._count_blocks[1][0] / self._weighted_base_blocks[1][0]
820
+ return WaveDiffSubtotal.subtotal_rows(
821
+ self._weighted_cube_counts.column_bases,
822
+ self._weighted_cube_counts.counts,
823
+ default_value,
824
+ self._dimensions,
825
+ )
813
826
 
814
827
  @lazyproperty
815
828
  def _weighted_base_blocks(self):
@@ -1564,17 +1577,18 @@ class _PairwiseSigTstats(_BaseSecondOrderMeasure):
1564
1577
  if self._second_order_measures.columns_squared_base.is_defined:
1565
1578
  weighted_blocks = self._second_order_measures.column_weighted_bases.blocks
1566
1579
  squared_blocks = self._second_order_measures.column_squared_bases.blocks
1567
- effective_blocks = [
1568
- [
1569
- weighted_blocks[0][0] ** 2 / squared_blocks[0][0],
1570
- weighted_blocks[0][1] ** 2 / squared_blocks[0][1],
1571
- ],
1572
- [
1573
- weighted_blocks[1][0] ** 2 / squared_blocks[1][0],
1574
- weighted_blocks[1][1] ** 2 / squared_blocks[1][1],
1575
- ],
1576
- ]
1577
- return effective_blocks
1580
+ with np.errstate(divide="ignore", invalid="ignore"):
1581
+ effective_blocks = [
1582
+ [
1583
+ weighted_blocks[0][0] ** 2 / squared_blocks[0][0],
1584
+ weighted_blocks[0][1] ** 2 / squared_blocks[0][1],
1585
+ ],
1586
+ [
1587
+ weighted_blocks[1][0] ** 2 / squared_blocks[1][0],
1588
+ weighted_blocks[1][1] ** 2 / squared_blocks[1][1],
1589
+ ],
1590
+ ]
1591
+ return effective_blocks
1578
1592
 
1579
1593
  unweighted_blocks = self._second_order_measures.column_unweighted_bases.blocks
1580
1594
  return unweighted_blocks
@@ -1845,6 +1859,14 @@ class _RowProportions(_BaseSecondOrderMeasure):
1845
1859
  contributed by the weighted count of each matrix cell.
1846
1860
  """
1847
1861
 
1862
+ @lazyproperty
1863
+ def _count_blocks(self):
1864
+ return self._second_order_measures.weighted_counts.blocks
1865
+
1866
+ @lazyproperty
1867
+ def _weighted_base_blocks(self):
1868
+ return self._second_order_measures.row_weighted_bases.blocks
1869
+
1848
1870
  @lazyproperty
1849
1871
  def blocks(self):
1850
1872
  """Nested list of the four 2D ndarray "blocks" making up this measure.
@@ -1854,8 +1876,8 @@ class _RowProportions(_BaseSecondOrderMeasure):
1854
1876
 
1855
1877
  Row-proportions are row comparable counts divided by the row weighted bases.
1856
1878
  """
1857
- count_blocks = self._second_order_measures.weighted_counts.blocks
1858
- weighted_base_blocks = self._second_order_measures.row_weighted_bases.blocks
1879
+ count_blocks = self._count_blocks
1880
+ weighted_base_blocks = self._weighted_base_blocks
1859
1881
 
1860
1882
  # --- do not propagate divide-by-zero warnings to stderr ---
1861
1883
  with np.errstate(divide="ignore", invalid="ignore"):
@@ -1864,16 +1886,36 @@ class _RowProportions(_BaseSecondOrderMeasure):
1864
1886
  # --- base values ---
1865
1887
  count_blocks[0][0] / weighted_base_blocks[0][0],
1866
1888
  # --- inserted columns ---
1867
- count_blocks[0][1] / weighted_base_blocks[0][1],
1889
+ self._inserted_columns,
1868
1890
  ],
1869
1891
  [
1870
1892
  # --- inserted rows ---
1871
- count_blocks[1][0] / weighted_base_blocks[1][0],
1893
+ self._inserted_rows,
1872
1894
  # --- intersections ---
1873
1895
  count_blocks[1][1] / weighted_base_blocks[1][1],
1874
1896
  ],
1875
1897
  ]
1876
1898
 
1899
+ @lazyproperty
1900
+ def _inserted_rows(self):
1901
+ default_value = self._count_blocks[1][0] / self._weighted_base_blocks[1][0]
1902
+ return WaveDiffSubtotal.subtotal_rows(
1903
+ self._weighted_cube_counts.row_bases,
1904
+ self._weighted_cube_counts.counts,
1905
+ default_value,
1906
+ self._dimensions,
1907
+ )
1908
+
1909
+ @lazyproperty
1910
+ def _inserted_columns(self):
1911
+ default_value = self._count_blocks[0][1] / self._weighted_base_blocks[0][1]
1912
+ return WaveDiffSubtotal.subtotal_columns(
1913
+ self._weighted_cube_counts.row_bases,
1914
+ self._weighted_cube_counts.counts,
1915
+ default_value,
1916
+ self._dimensions,
1917
+ )
1918
+
1877
1919
 
1878
1920
  class _RowShareSum(_BaseSecondOrderMeasure):
1879
1921
  """Provides the row share of sum measure for a matrix.
@@ -12,6 +12,7 @@ primarily used by measure objects as a collaborator to handle this aspect.
12
12
 
13
13
  import numpy as np
14
14
 
15
+ from cr.cube.enums import DIMENSION_TYPE as DT
15
16
  from cr.cube.util import lazyproperty
16
17
 
17
18
 
@@ -370,6 +371,136 @@ class SumSubtotals(_BaseSubtotals):
370
371
  return addend_sum - subtrahend_sum
371
372
 
372
373
 
374
+ class WaveDiffSubtotal:
375
+ """Subtotal "blocks" created by adding and subtracting terms for wave differences.
376
+
377
+ This class handles a special case for wave differences when a CAT_DATE variable is
378
+ involved in the calculation.
379
+
380
+ A wave difference for a CAT_DATE variable is calculate subtracting at the
381
+ percentages level: (count1/base1) - (count2/base2).
382
+ """
383
+
384
+ def __init__(self, base_values, counts, default_insertions, dimensions):
385
+ self._base_values = base_values
386
+ self._counts = counts
387
+ self._default_insertions = default_insertions
388
+ self._dimensions = dimensions
389
+
390
+ @classmethod
391
+ def subtotal_columns(cls, base_values, counts, default_insertions, dimensions):
392
+ """Return (n_column_subtotals, n_base_rows) ndarray of subtotal columns."""
393
+ return cls(
394
+ base_values, counts, default_insertions, dimensions
395
+ )._subtotal_columns
396
+
397
+ @classmethod
398
+ def subtotal_rows(cls, base_values, counts, default_insertions, dimensions):
399
+ """Return (n_row_subtotals, n_base_cols) ndarray of subtotal rows.
400
+ Keyword arguments:
401
+ `diff_cols_nan` -- Overrides subtotal differences in the columns direction eg
402
+ for column bases (default False)
403
+ `diff_rows_nan` -- Overrides subtotal differences in the rows direction eg for
404
+ row bases (default False)
405
+ """
406
+ return cls(base_values, counts, default_insertions, dimensions)._subtotal_rows
407
+
408
+ @lazyproperty
409
+ def _column_subtotals(self):
410
+ """Sequence of _Subtotal object for each subtotal in columns-dimension."""
411
+ return self._dimensions[1].subtotals
412
+
413
+ def _multiple_subtrahends_or_addends(self, subtotal):
414
+ """Returns true if the subtotal has multiple addend or subtrahend terms."""
415
+ return any(subtotal.subtrahend_idxs) and (
416
+ len(subtotal.subtrahend_idxs) > 1 or len(subtotal.addend_idxs) > 1
417
+ )
418
+
419
+ def _nan_subtotals(self, axis):
420
+ """Generate an array filled with NaN values.
421
+
422
+ Matches the size of the specified axis of the base values.
423
+ """
424
+ return np.full(self._base_values.shape[axis], np.nan)
425
+
426
+ @lazyproperty
427
+ def _row_subtotals(self):
428
+ """Sequence of _Subtotal object for each subtotal in rows-dimension."""
429
+ return self._dimensions[0].subtotals
430
+
431
+ @lazyproperty
432
+ def _subtotal_rows(self):
433
+ """(n_row_subtotals, n_cols) ndarray of subtotal rows."""
434
+ subtotals = self._row_subtotals
435
+ n_cols = self._base_values.shape[1]
436
+ if len(subtotals) == 0:
437
+ return np.empty((0, n_cols))
438
+
439
+ return np.vstack(
440
+ [
441
+ self._subtotal_row(subtotal, default)
442
+ for subtotal, default in zip(subtotals, self._default_insertions)
443
+ ]
444
+ )
445
+
446
+ @lazyproperty
447
+ def _subtotal_columns(self):
448
+ """(n_rows, n_col_subtotals) matrix of subtotal columns."""
449
+ subtotals = self._column_subtotals
450
+ n_rows = self._base_values.shape[0]
451
+ if len(subtotals) == 0:
452
+ return np.empty((n_rows, 0))
453
+ return np.hstack(
454
+ [
455
+ self._subtotal_column(subtotal, default).reshape(n_rows, 1)
456
+ for subtotal, default in zip(subtotals, self._default_insertions.T)
457
+ ]
458
+ )
459
+
460
+ def _subtotal_column(self, subtotal, default):
461
+ """Return (n_rows,) ndarray of values for `subtotal` column."""
462
+ if self._dimensions[1].dimension_type == DT.CAT_DATE and any(
463
+ subtotal.subtrahend_idxs
464
+ ):
465
+ if self._multiple_subtrahends_or_addends(subtotal):
466
+ return self._nan_subtotals(axis=0)
467
+ base_addend_sum = np.sum(self._base_values[:, subtotal.addend_idxs], axis=1)
468
+ base_subtrahend_sum = np.sum(
469
+ self._base_values[:, subtotal.subtrahend_idxs], axis=1
470
+ )
471
+ counts_addend_sum = np.sum(self._counts[:, subtotal.addend_idxs], axis=1)
472
+ counts_subtrahend_sum = np.sum(
473
+ self._counts[:, subtotal.subtrahend_idxs], axis=1
474
+ )
475
+ return (counts_addend_sum / base_addend_sum) - (
476
+ counts_subtrahend_sum / base_subtrahend_sum
477
+ )
478
+
479
+ return default
480
+
481
+ def _subtotal_row(self, subtotal, default):
482
+ """Return (n_cols,) ndarray of values for `subtotal` row."""
483
+
484
+ if self._dimensions[0].dimension_type == DT.CAT_DATE and any(
485
+ subtotal.subtrahend_idxs
486
+ ):
487
+ if self._multiple_subtrahends_or_addends(subtotal):
488
+ return self._nan_subtotals(axis=1)
489
+ base_addend_sum = np.sum(self._base_values[subtotal.addend_idxs, :], axis=0)
490
+ base_subtrahend_sum = np.sum(
491
+ self._base_values[subtotal.subtrahend_idxs, :], axis=0
492
+ )
493
+ counts_addend_sum = np.sum(self._counts[subtotal.addend_idxs, :], axis=0)
494
+ counts_subtrahend_sum = np.sum(
495
+ self._counts[subtotal.subtrahend_idxs, :], axis=0
496
+ )
497
+ return (counts_addend_sum / base_addend_sum) - (
498
+ counts_subtrahend_sum / base_subtrahend_sum
499
+ )
500
+
501
+ return default
502
+
503
+
373
504
  class OverlapSubtotals(SumSubtotals):
374
505
  """Subtotal blocks used exclusively for the "overlap" cube measure.
375
506
 
@@ -12,6 +12,7 @@ primarily used by measure objects as a collaborator to handle this aspect.
12
12
 
13
13
  import numpy as np
14
14
 
15
+ from cr.cube.enums import DIMENSION_TYPE as DT
15
16
  from cr.cube.util import lazyproperty
16
17
 
17
18
 
@@ -104,3 +105,64 @@ class SumSubtotals(_BaseSubtotals):
104
105
  subtrahend_sum = np.sum(base_values[subtotal.subtrahend_idxs])
105
106
 
106
107
  return addend_sum - subtrahend_sum
108
+
109
+
110
+ class WaveDiffSubtotals(_BaseSubtotals):
111
+ """Subtotal "blocks" created by adding and subtracting terms for wave differences.
112
+
113
+ This class handles a special case for wave differences when a CAT_DATE variable is
114
+ involved in the calculation.
115
+
116
+ A wave difference for a CAT_DATE variable is calculate subtracting at the
117
+ percentages level: (count1/base1) - (count2/base2).
118
+ """
119
+
120
+ def __init__(self, base_values, counts, default_values, rows_dimension):
121
+ super(WaveDiffSubtotals, self).__init__(base_values, rows_dimension)
122
+ self._counts = counts
123
+ self._default_values = default_values
124
+
125
+ @classmethod
126
+ def subtotal_values(cls, base_values, counts, default_values, rows_dimension):
127
+ """Return (n_row_subtotals,) ndarray of subtotal values."""
128
+ return cls(base_values, counts, default_values, rows_dimension)._subtotal_values
129
+
130
+ def _multiple_subtrahends_or_addends(self, subtotal):
131
+ """Returns true if the subtotal has multiple addend or subtrahend terms."""
132
+ return any(subtotal.subtrahend_idxs) and (
133
+ len(subtotal.subtrahend_idxs) > 1 or len(subtotal.addend_idxs) > 1
134
+ )
135
+
136
+ @lazyproperty
137
+ def _subtotal_values(self):
138
+ """(n_row_subtotals,) ndarray of subtotal values for stripe."""
139
+ subtotals = self._row_subtotals
140
+
141
+ if len(subtotals) == 0:
142
+ return np.array([])
143
+
144
+ if self._rows_dimension.dimension_type != DT.CAT_DATE:
145
+ return self._default_values
146
+
147
+ return np.array(
148
+ [
149
+ self._subtotal_value(subtotal, default)
150
+ for subtotal, default in zip(subtotals, self._default_values)
151
+ ]
152
+ )
153
+
154
+ def _subtotal_value(self, subtotal, default):
155
+ """Return scalar value of wafe diff `subtotal` row."""
156
+ if len(subtotal.subtrahend_idxs) > 0 and len(subtotal.addend_idxs) > 0:
157
+ if self._multiple_subtrahends_or_addends(subtotal):
158
+ return np.nan
159
+ base_values = self._base_values
160
+ counts = self._counts
161
+ base_addend_sum = np.sum(base_values[subtotal.addend_idxs])
162
+ base_subtrahend_sum = np.sum(base_values[subtotal.subtrahend_idxs])
163
+ counts_addend_sum = np.sum(counts[subtotal.addend_idxs])
164
+ counts_subtrahend_sum = np.sum(counts[subtotal.subtrahend_idxs])
165
+ return (counts_addend_sum / base_addend_sum) - (
166
+ counts_subtrahend_sum / base_subtrahend_sum
167
+ )
168
+ return default
@@ -12,6 +12,7 @@ from cr.cube.stripe.insertion import (
12
12
  NegativeTermSubtotals,
13
13
  PositiveTermSubtotals,
14
14
  SumSubtotals,
15
+ WaveDiffSubtotals,
15
16
  )
16
17
  from cr.cube.util import lazyproperty
17
18
 
@@ -628,7 +629,13 @@ class _TableProportions(_BaseSecondOrderMeasure):
628
629
 
629
630
  # --- do not propagate divide-by-zero warnings to stderr ---
630
631
  with np.errstate(divide="ignore", invalid="ignore"):
631
- return subtotal_values / weighted_table_base
632
+ default_value = subtotal_values / weighted_table_base
633
+ return WaveDiffSubtotals.subtotal_values(
634
+ self._weighted_cube_counts.bases,
635
+ self._weighted_cube_counts.counts,
636
+ default_value,
637
+ self._rows_dimension,
638
+ )
632
639
 
633
640
 
634
641
  class _UnweightedBases(_BaseSecondOrderMeasure):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: cr.cube
3
- Version: 3.0.45
3
+ Version: 3.1.0
4
4
  Summary: Crunch.io Cube library
5
5
  Home-page: https://github.com/Crunch-io/crunch-cube/
6
6
  Author: Crunch.io
@@ -118,6 +118,9 @@ Description: # crunch-cube
118
118
 
119
119
  ## Changes
120
120
 
121
+ ### 3.1.0
122
+ - Subtotal diff (wave difference) for categorical date dimensions
123
+
121
124
  ### 3.0.45
122
125
  - Enumerator refactoring
123
126