diff --git a/docs/CONDUCT.html b/docs/CONDUCT.html index 77bca0f0..4ba2dbf8 100644 --- a/docs/CONDUCT.html +++ b/docs/CONDUCT.html @@ -1,6 +1,6 @@ - + @@ -8,18 +8,25 @@ Contributor Code of Conduct • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ CONTRIBUTING • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ License • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + + Exploring Imputed Values • naniar - - - - + + + + + + + + + + + - @@ -24,14 +31,15 @@
@@ -259,17 +276,17 @@

One thing that we notice with our imputations are that they aren’t very good - we can improve upon the imputation by including the variables year and latitude and longitude:

ocean_imp_yr <- oceanbuoys %>%
   bind_shadow() %>%
-  impute_lm(air_temp_c ~ wind_ew + wind_ns + year + longitude + latitude) %>%
-  impute_lm(humidity ~  wind_ew + wind_ns + year + longitude + latitude) %>%
-  impute_lm(sea_temp_c ~  wind_ew + wind_ns + year + longitude + latitude) %>%
+  impute_lm(air_temp_c ~ wind_ew + wind_ns + year + longitude + latitude) %>%
+  impute_lm(humidity ~  wind_ew + wind_ns + year + longitude + latitude) %>%
+  impute_lm(sea_temp_c ~  wind_ew + wind_ns + year + longitude + latitude) %>%
   add_label_shadow()
-
ggplot(ocean_imp_yr,
-       aes(x = air_temp_c,
+
ggplot(ocean_imp_yr,
+       aes(x = air_temp_c,
            y = humidity,
            color = any_missing)) + 
-  geom_point() +
-  scale_color_brewer(palette = "Dark2") +
-  theme(legend.position = "bottom")
+ geom_point() + + scale_color_brewer(palette = "Dark2") + + theme(legend.position = "bottom")

@@ -279,9 +296,9 @@

Hmisc aregImpute

-

We can explore using a single imputation of Hmisc::aregImpute(), which allows for multiple imputation with bootstrapping, additive regression, and predictive mean matching. We are going to explore predicting mean matching, and single imputation.

+

We can explore using a single imputation of Hmisc::aregImpute(), which allows for multiple imputation with bootstrapping, additive regression, and predictive mean matching. We are going to explore predicting mean matching, and single imputation.

+aq_nab$Ozone[is.na(aq_nab$Ozone)] <- aq_imp$imputed$Ozone +aq_nab$Solar.R[is.na(aq_nab$Solar.R)] <- aq_imp$imputed$Solar.R

In the future there will be a more concise way to insert these imputed values into data, but for the moment the method above is what I would recommend for single imputation.

We can then explore the imputed values like so:


-ggplot(aq_nab,
-       aes(x = Ozone,
+ggplot(aq_nab,
+       aes(x = Ozone,
            y = Solar.R,
            colour = any_missing)) + 
-  geom_point()
+ geom_point()

@@ -378,14 +395,13 @@

-

Site built with pkgdown.

+

Site built with pkgdown 1.3.0.

- - - - - + + + + + + + + + + + - @@ -24,14 +31,15 @@

Numerical summaries of missing values

-

naniar also provide numerical summaries for missing data. Two convenient counters of complete values and missings are n_miss() and n_complete(). These work on both dataframes and vectors, similar to dplyr::n_distinct()

-
dplyr::n_distinct(airquality)
+

naniar also provide numerical summaries for missing data. Two convenient counters of complete values and missings are n_miss() and n_complete(). These work on both dataframes and vectors, similar to dplyr::n_distinct()

+
dplyr::n_distinct(airquality)
## [1] 153
-
dplyr::n_distinct(airquality$Ozone)
+
dplyr::n_distinct(airquality$Ozone)
## [1] 68
n_miss(airquality)
## [1] 44
@@ -405,7 +413,7 @@

## 8 32 1 16.7 ## 9 33 1 16.7 ## 10 34 1 16.7 -## # ... with 143 more rows +## # … with 143 more rows

miss_case_table() tabulates the number of missing values in a case / row. Below, this shows the number of missings in a case:

  • There are 111 cases with 0 missings, which comprises about 72% of the data.
  • @@ -481,7 +489,7 @@

    ## 8 744 missing ## 9 7420 complete ## 10 1 missing -## # ... with 25 more rows +## # … with 25 more rows

    miss_var_span() is used to determine the number of missings over a specified repeating span of rows in variable of a dataframe. Similar to miss_var_run(), you specify the variable that you wish to explore, you then also specify the size of the span with the span_every argument.

    miss_var_span(pedestrian,
                   hourly_counts,
    @@ -499,13 +507,13 @@ 

    ## 8 8 0 100 0 1 ## 9 9 0 100 0 1 ## 10 10 0 100 0 1 -## # ... with 367 more rows

    +## # … with 367 more rows

-Using group_by() with naniar

-

Every miss_* summary function that returns a dataframe can be used with dplyr group_by(). For example, if you would like to look at the number of missing values for all variables of pedestrian data.

+Using group_by() with naniar

+

Every miss_* summary function that returns a dataframe can be used with dplyr group_by(). For example, if you would like to look at the number of missing values for all variables of pedestrian data.

pedestrian %>% miss_var_summary()
## # A tibble: 9 x 3
 ##   variable      n_miss pct_miss
@@ -521,9 +529,9 @@ 

## 9 sensor_name 0 0

We see that this is in hourly_counts. We can then explore this by month, and filder by the variable being hourly_counts, since it is the only one with missing values.

pedestrian %>%
- group_by(month) %>%
+ group_by(month) %>%
  miss_var_summary() %>%
- filter(variable == "hourly_counts")
+ filter(variable == "hourly_counts")
## # A tibble: 12 x 4
 ##    month     variable      n_miss pct_miss
 ##    <ord>     <chr>          <int>    <dbl>
@@ -551,7 +559,7 @@ 

Here, the approach is to predict the proportion of missingness in a given case, using all variables. There is a little helper function to add a column with the proportion of cases or rows missing - add_prop_miss(). This created a column named “prop_miss”, which is the proportion of missing values in that row.

+ head()

##   Ozone Solar.R Wind Temp Month Day prop_miss_all
 ## 1    41     190  7.4   67     5   1     0.0000000
 ## 2    36     118  8.0   72     5   2     0.0000000
@@ -560,13 +568,13 @@ 

## 5 NA NA 14.3 56 5 5 0.3333333 ## 6 28 NA 14.9 66 5 6 0.1666667

We can then use a model like decision trees to predict which variables and their values are important for predicting the proportion of missingness:

-
library(rpart)
-library(rpart.plot)
+
library(rpart)
+library(rpart.plot)
 
 airquality %>%
   add_prop_miss() %>%
-  rpart(prop_miss_all ~ ., data = .) %>%
-  prp(type = 4, extra = 101, prefix = "Prop. Miss = ")
+ rpart(prop_miss_all ~ ., data = .) %>% + prp(type = 4, extra = 101, prefix = "Prop. Miss = ")
## Warning: Cannot retrieve the data used to build the model (so cannot determine roundint and is.binary for the variables).
 ## To silence this warning:
 ##     Call prp with roundint=FALSE,
@@ -633,7 +641,7 @@ 

  • Numerical summaries of missing values
  • -
  • Using group_by() with naniar
  • +
  • Using group_by() with naniar
  • Modelling missingness
  • Summary
  • Future development
  • @@ -651,14 +659,13 @@

    -

    Site built with pkgdown.

    +

    Site built with pkgdown 1.3.0.

    - - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + + Gallery of Missing Data Visualisations • naniar - - - - + + + + + + + + + + + - @@ -24,14 +31,15 @@
    @@ -368,14 +391,13 @@

    -

    Site built with pkgdown.

    +

    Site built with pkgdown 1.3.0.

    - - - - - + + + + + + + + + + + - @@ -24,14 +31,15 @@

    +

    You could also group_by() to work out the number of missings in each variable across the levels within it.

    +#> # … with 15 more rows

    You can read more about all of these functions in the vignette “Getting Started with naniar”.

    @@ -420,10 +428,10 @@

    License

    Developers

      -
    • Nicholas Tierney
      Author, maintainer
    • -
    • Di Cook
      Author
    • -
    • Miles McBain
      Author
    • -
    • Colin Fay
      Author
    • +
    • Nicholas Tierney
      Author, maintainer ORCID
    • +
    • Di Cook
      Author ORCID
    • +
    • Miles McBain
      Author ORCID
    • +
    • Colin Fay
      Author ORCID
    • All authors...
    @@ -449,14 +457,13 @@

    Dev status

    -

    Site built with pkgdown.

    +

    Site built with pkgdown 1.3.0.

    - - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ Changelog • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ NA • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ Add a column describing presence of any missing values — add_any_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -45,12 +52,15 @@ will be called "any_miss_all", if no variables are specified, otherwise, if variables are specified, the label will be "any_miss_vars" to indicate that not all variables have been used to create the labels." /> + + - + + - + @@ -8,18 +8,25 @@ Add a column describing if there are any missings in the dataset — add_label_missings • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add a column describing whether there is a shadow — add_label_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ focus on whether there have been any shadows created. This can be useful when data has been imputed and you need to determine which rows contained missing values when the shadow was bound to the dataset." /> + + - + + - + @@ -8,18 +8,25 @@ Add a column that tells us which "missingness cluster" a row belongs to — add_miss_cluster • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ see some clustering in the data, but you do not have a way to identify the cluster. Future work will incorporate the seriation package to allow for better control over the clustering from the user." /> + + - + + - + @@ -8,18 +8,25 @@ Add column containing number of missing data values — add_n_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add column containing proportion of missing data values — add_prop_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ "prop_miss", which contains the proportion of missing values in that row. You can specify the variables that you would like to show the missingness for." /> + + - + + - + @@ -8,18 +8,25 @@ Add a shadow column to dataframe — add_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add a shadow shifted column to a dataset — add_shadow_shift • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add a counter variable for a span of dataframe — add_span_counter • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Identify if all values are missing or complete — all-is-miss-complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Helper function to determine whether all rows are complete — all_row_complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Helper function to determine whether all rows are missing — all_row_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Identify if there are any missing or complete values — any-na • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ Are two functions that do this in naniar - any_miss and it's alias any_na. These bother under the hood call anyNA. any_complete is the complement to any_miss - it returns TRUE if there are any complete values." /> + + - + + - + @@ -8,18 +8,25 @@ Helper function to determine whether there are any missings — any_row_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Create shadow data — as_shadow.data.frame • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Create shadows — as_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -44,12 +51,15 @@ of missingness of data values, where missing is represented as "NA", and not missing is represented as "!NA". Although these may be represented as 1 and 0, respectively." /> + + - + + - + @@ -8,18 +8,25 @@ Convert data into shadow format for doing an upset plot — as_shadow_upset • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Bind a shadow dataframe to original data — bind_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add a shadow column to a dataset — cast_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -46,12 +53,15 @@ block for the functions cast_shadow_shift, and cast_shadow_shift_label. It also respects the dplyr verbs starts_with, contains, ends_with, etc. to select variables." /> + + - + + - + @@ -8,18 +8,25 @@ Add a shadow and a shadow_shift column to a dataset — cast_shadow_shift • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add a shadow column and a shadow shifted column to a dataset — cast_shadow_shift_label • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Common number values for NA — common_na_numbers • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -45,12 +52,15 @@ possible missings, but I strongly warn against using this to replace NA values without very carefully looking at the incidence for each of the cases. Common NA strings are in the data object common_na_strings." /> + + - + + - + @@ -8,18 +8,25 @@ Common string values for NA — common_na_strings • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -48,12 +55,15 @@ uses \ around the "?", "." and "*" characters to protect against using their wildcard features in grep. Common NA numbers are in the data object common_na_numbers." /> + + - + + - + @@ -8,18 +8,25 @@ Key drawing functions — draw_key • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Long form representation of a shadow matrix — gather_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ geom_miss_point — geom_miss_point • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ values in ggplot2. To do so it uses methods from ggobi to display missing data points 10% below the minimum value, so that the values can be seen on the same axis." /> + + - + + - + @@ -8,18 +8,25 @@ Plot the number of missings per case (row) — gg_miss_case • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Plot of cumulative sum of missing for cases — gg_miss_case_cumsum • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Plot the number of missings for each variable, broken down by a factor — gg_miss_fct • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Plot the number of missings in a given repeating span — gg_miss_span • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ imputeTS::plotNA.distributionBar(tsNH4, breaksize = 100), which shows the number of missings in a given span, or breaksize. A default minimal theme is used, which can be customised as normal for ggplot." /> + + - + + - + @@ -8,18 +8,25 @@ Plot the pattern of missingness using an upset plot. — gg_miss_upset • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Plot the number of missings for each variable — gg_miss_var • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ number of missings in each variable, ordered to show which variables have the most missing data. A default minimal theme is used, which can be customised as normal for ggplot." /> + + - + + - + @@ -8,18 +8,25 @@ Plot of cumulative sum of missing value for each variable — gg_miss_var_cumsum • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Plot which variables contain a missing value — gg_miss_which • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Group By Helper — group_by_fun • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Impute data with values shifted 10% below range. — impute_below • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -44,12 +51,15 @@ values adds a new string or label. It is powered by shadow_shift, so please see the documentation for shadow_shift() to full details on the different implementations." /> + + - + + - + @@ -8,18 +8,25 @@ Impute data with values shifted 10% below range. — impute_below_all • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ the data. impute_below_all imputes all variables with missings to have values 10 values adds a new string or label." /> + + - + + - + @@ -8,18 +8,25 @@ Scoped variants of <code>impute_below</code> — impute_below_at • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ that satisfy a specific condition, use the scoped variants, impute_below_at, and impute_below_if. To use _at effectively, you must know that _at`` affects variables selected with a character vector, or with vars()`." /> + + - + + - + @@ -8,18 +8,25 @@ Scoped variants of <code>impute_below</code> — impute_below_if • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Impute the mean value into a vector with missing values — impute_mean • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Impute the median value into a vector with missing values — impute_median • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Function reference • naniar + + + + + + + - + - + - + - + - + @@ -31,17 +38,21 @@ - + + + + - + + - + @@ -8,18 +8,25 @@ Detect if this is a shade — is_shade • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Test if input is or are shadow variables — is_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Label a missing from one column — label_miss_1d • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ label_miss_2d — label_miss_2d • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Is there a missing value in the row of a dataframe? — label_missings • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Label shadow values as missing or not missing — label_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Percentage of cases that contain a missing or complete values. — miss-complete-case-pct • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Proportion of cases that contain a missing or complete values. — miss-complete-case-prop • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Percentage of variables containing missings or complete values — miss-complete-var-pct • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Proportion of variables containing missings or complete values — miss-complete-var-prop • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Summarise the missingness in each case — miss_case_summary • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Tabulate missings in cases. — miss_case_table • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Proportions of missings in data, variables, and cases. — miss_prop_summary • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ Specifically, returning how many elements in a dataframe contain a missing value, how many elements in a variable contain a missing value, and how many elements in a case contain a missing." /> + + - + + - + @@ -8,18 +8,25 @@ Search and present different kinds of missing values — miss_scan_count • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -44,12 +51,15 @@ if they are there, and if so, where they are. miss_scan_count makes it easier for users to search for particular occurrences of these values across their variables." /> + + - + + - + @@ -8,18 +8,25 @@ Collate summary measures from naniar into one tibble — miss_summary • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Find the number of missing and complete values in a single run — miss_var_run • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ The function, miss_var_run(), returns a dataframe with the column names "run_length" and "is_na", which describe the length of the run, and whether that run describes a missing value." /> + + - + + - + @@ -8,18 +8,25 @@ Summarise the number of missings for a given repeating span on a variable — miss_var_span • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ miss_var_span takes a data.frame object, a variable, and a span_every argument and returns a dataframe containing the number of missing values within each span." /> + + - + + - + @@ -8,18 +8,25 @@ Summarise the missingness in each variable — miss_var_summary • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Tabulate the missings in the variables — miss_var_table • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Which variables contain missing values? — miss_var_which • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ of the variables that contain missing values. miss_var_which returns a vector of variable names that contain missings. It will return NULL when there are no missings." /> + + - + + - + @@ -8,18 +8,25 @@ The number of variables with complete values — n-var-case-complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ The number of variables or cases with missing values — n-var-case-miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the number of complete values — n_complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return a vector of the number of complete values in each row — n_complete_row • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the number of missing values — n_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return a vector of the number of missing values in each row — n_miss_row • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Convert data into nabular form by binding shade to it — nabular • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ naniar-ggproto — GeomMissPoint • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ naniar — naniar • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Create a new nabular format — new_nabular • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Create a new shade factor — new_shade • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Create a new shadow — new_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ West Pacific Tropical Atmosphere Ocean Data, 1993 & 1997. — oceanbuoys • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ and prediction of El Ni'o and La Ni'a. The data is collected by the Tropical Atmosphere Ocean project (http://www.pmel.noaa.gov/tao/index.shtml)." /> + + - + + - + @@ -8,18 +8,25 @@ Percentage of cases that contain a missing or complete values. — pct-miss-complete-case • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Percentage of variables containing missings or complete values — pct-miss-complete-var • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the percent of complete values — pct_complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the percent of missing values — pct_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Pedestrian count information around Melbourne for 2016 — pedestrian • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ Spencer St-Collins St (south), recorded from January 1st 2016 at 00:00:00 to December 31st 2016 at 23:00:00. The data is made free and publicly available from https://data.melbourne.vic.gov.au/Transport-Movement/Pedestrian-volume-updated-monthly-/b2ak-trbp" /> + + - + + + + + + + + + +Plotly helpers (Convert a geom to a "basic" geom.) — plotly_helpers • naniar + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    + + + +
    + +
    +
    + + +
    + +

    Helper functions to make it easier to automatically create +plotly charts. This function makes it possible to convert ggplot2 geoms +that are not included with ggplot2 itself. Users shouldn't need to use this +function. It exists purely to allow other package authors to write their +own conversion method(s).

    + +
    + +
    to_basic.GeomMissPoint(data, prestats_data, layout, params, p, ...)
    + +

    Arguments

    + + + + + + + + + + + + + + + + + + + + + + + + + + +
    data

    the data returned by ggplot2::ggplot_build().

    prestats_data

    the data before statistics are computed.

    layout

    the panel layout.

    params

    parameters for the geom, statistic, and 'constant' aesthetics

    p

    a ggplot2 object (the conversion may depend on scales, for +instance).

    ...

    currently ignored

    + + +
    + +
    + +
    + + +
    +

    Site built with pkgdown 1.3.0.

    +
    +
    +
    + + + + + + + + + diff --git a/docs/reference/prop-miss-complete-case.html b/docs/reference/prop-miss-complete-case.html index cd1afa3f..a028a31b 100644 --- a/docs/reference/prop-miss-complete-case.html +++ b/docs/reference/prop-miss-complete-case.html @@ -1,6 +1,6 @@ - + @@ -8,18 +8,25 @@ Proportion of cases that contain a missing or complete values. — prop-miss-complete-case • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Proportion of variables containing missings or complete values — prop-miss-complete-var • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the proportion of complete values — prop_complete • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return a vector of the proportion of missing values in each row — prop_complete_row • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return the proportion of missing values — prop_miss • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Return a vector of the proportion of missing values in each row — prop_miss_row • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Add special missing values to the shadow matrix — recode_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Objects exported from other packages — reexports • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -47,12 +54,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Replace values with missings — replace_to_na • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Replace values with missings — replace_with_na • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Replace all values with NA where a certain condition is met — replace_with_na_all • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Replace specified variables with NA where a certain condition is met — replace_with_na_at • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Replace values with NA based on some condition, for variables that meet some predicate — replace_with_na_if • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -9,18 +9,25 @@ The Behavioral Risk Factor Surveillance System (BRFSS) Survey Data, 2009. — riskfactors • naniar + + + + + + + - + - + - + - + - + @@ -32,7 +39,7 @@ - + @@ -43,12 +50,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Scoped variants of <code>impute_mean</code> — scoped-impute_mean • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ that satisfy a specific condition, use the scoped variants, impute_below_at, and impute_below_if. To use _at effectively, you must know that _at`` affects variables selected with a character vector, or with vars()`." /> + + - + + - + @@ -8,18 +8,25 @@ Scoped variants of <code>impute_median</code> — scoped-impute_median • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ that satisfy a specific condition, use the scoped variants, impute_below_at, and impute_below_if. To use _at effectively, you must know that _at`` affects variables selected with a character vector, or with vars()`." /> + + - + + - + @@ -8,18 +8,25 @@ Create new levels of missing — shade • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -42,12 +49,15 @@ not missing, and NA indicates missingness. It also allows you to specify some new missings, if you like. This function is what powers the factor levels in as_shadow()." /> + + - + + - + @@ -8,18 +8,25 @@ Expand and relevel a shadow column with a new suffix — shadow_expand_relevel • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Reshape shadow data into a long format — shadow_long • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Shift missing values to facilitate missing data exploration/visualisation — shadow_shift • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -43,12 +50,15 @@ variables, the values are shifted to 10 variable plus some jittered noise, to separate repeated values, so that missing values can be visualised along with the rest of the data." /> + + - + + - + @@ -8,18 +8,25 @@ Shift (impute) numeric values for graphical exploration — shadow_shift.numeric • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ stat_miss_point — stat_miss_point • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Test if input is a data.frame — test_if_dataframe • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Test if the input is Missing — test_if_missing • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Test if the input is NULL — test_if_null • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Test if input is a shadow — test_if_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Unbind (remove) shadow from data, and vice versa — unbinders • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Expand all shadow levels — update_shadow • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ check the levels of many things — what_levels • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Split a call into two components with a useful verb name — where • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -41,12 +48,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Which rows and cols contain missings? — where_na • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -40,12 +47,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Which variables are shades? — which_are_shade • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + + - + @@ -8,18 +8,25 @@ Which elements contain missings? — which_na • naniar + + + + + + + - + - + - + - + - + @@ -31,7 +38,7 @@ - + @@ -39,12 +46,15 @@ + + - + +