Skip to content

spsurvey 5.4.0

Compare
Choose a tag to compare
@michaeldumelle michaeldumelle released this 22 Nov 18:10
· 36 commits to main since this release
3ab9585

Minor Updates

  • Added an sp_frame() function to create sp_frame objects for use with plot() and summary() for sampling frames and analysis data.
    • sp_frame objects have class sp_frame.
  • Added an sp_unframe() function to transform sp_frame objects back into their original object type.
  • Objects output from grts() and irs() are now called sp_design objects instead of spdesign objects.
    • sp_design objects have class sp_design.
  • summary() now works with sp_frame objects and sp_design objects.
    • sp_summary() yields equivalent summaries and is currently maintained for backwards compatibility (i.e., sp_summary() has not changed).
  • summary functions now also summarize sf object geometries if the name of the geometry list-column is provided in the summary formula.
  • plot() now works with sp_frame objects and sp_design objects.
    • sp_plot() yields equivalent plots and is currently maintained for backwards compatibility (i.e., sp_plot() has not changed).
  • plot() now works with sp_CDF objects that are output from the CDF element of cont_analysis().
    • cdf_plot() yields equivalent plots and is currently maintained for backwards compatibility (i.e., cdf_plot() has not changed).
  • Updated print functions for summaries obtained via summary() or sp_summary() so that they are clearer and easier to read.
  • Added a print function for sp_design objects. Now, a summary of site counts by site type (Legacy, Base, Over Near) crossed by strata or unequal probability levels or both is provided.
  • Added stratum_var, caty_var, and aux_var elements to the design list in sp_design objects.
  • Added legacy_stratum_var, legacy_caty_var, and legacy_aux_var elements to the design list in sp_design objects when legacy sites are used.
  • Added a "total" option to test in change_analysis().
  • Minor documentation updates.
  • Minor vignette updates.
  • Minor stability updates.

Bug fixes

  • Fixed a bug that prevented proper printing of the Indicator column when using change_analysis() with test = median.
  • Fixed a bug that made change_analysis sensititve to the ordering of the levels of variables in var_cat if those variables were factors.
  • Fixed a bug in sp_summary() that incorrectly ordered the siteuse variable.
  • Fixed a bug in sp_summary() that failed to summarize data frames that did not have an sf_column attribute.
  • Fixed a bug in *_analysis() functions when popsize is a list intended for use with survey::calibrate().
  • Fixed a bug in *analysis() functions that returned an error while performing percentile estimation when there was no variability in at least one variable in vars for at least one level of one variable in subpops.
  • Fixed a bug in grts() that caused an error for some combinations of n_base and n_over.
  • Fixed a bug in change_analysis() that returned an error when at least one varible in vars_cat has only one unique value.