Comments (2)
Perhaps something like this?
library(naniar)
library(brolgar)
library(dplyr)
#>
#> Attaching package: 'dplyr'
#> The following objects are masked from 'package:stats':
#>
#> filter, lag
#> The following objects are masked from 'package:base':
#>
#> intersect, setdiff, setequal, union
wages %>%
group_by(id) %>%
miss_case_summary() %>%
filter(n_miss > 0) %>%
arrange(-n_miss)
#> # A tibble: 799 x 4
#> id case n_miss pct_miss
#> <int> <int> <int> <dbl>
#> 1 2766 6 2 14.3
#> 2 2786 3 2 14.3
#> 3 3340 3 2 14.3
#> 4 4068 7 2 14.3
#> 5 6439 8 2 14.3
#> 6 6762 9 2 14.3
#> 7 9093 2 2 14.3
#> 8 9436 2 2 14.3
#> 9 10330 6 2 14.3
#> 10 53 5 1 7.14
#> # … with 789 more rows
wages %>%
group_by(id) %>%
summarise_at(.vars = vars(lnw),
.funs = list(n_miss = function(x) sum(is.na(x)))) %>%
arrange(-n_miss)
#> # A tibble: 888 x 2
#> id n_miss
#> <int> <int>
#> 1 31 0
#> 2 36 0
#> 3 53 0
#> 4 122 0
#> 5 134 0
#> 6 145 0
#> 7 155 0
#> 8 173 0
#> 9 206 0
#> 10 207 0
#> # … with 878 more rows
Created on 2019-04-09 by the reprex package (v0.2.1)
from brolgar.
- Aim to move any new functions from this into
naniar
. - Aim to demonstrate missingness functions in a workflow
from brolgar.
Related Issues (20)
- Add `feat_diff_summary` HOT 1
- rexport some of the metadata functions
- option to meaningfully label the facet names of facet_strata HOT 2
- Expected behaviour for grouped data + sample_n_keys HOT 5
- Including an option for a shadow for all data HOT 8
- improve documentation for facet_sample / facet_strata and constructors
- features with multiple variables
- New approach to adding strata with a join creates wayy to many rows HOT 1
- Make facet_sample and facet_strata have more flexible defaults HOT 1
- Example of facet_sample / facet_strata working with factor type data
- facet_sample should label facets with the id HOT 2
- multiple geom's with `facet_sample` are treated separately
- Release brolgar 1.0.0
- rename `key_slope` to `feat_lm` ? HOT 2
- addhealth data, for data in paper. HOT 1
- double check if PISA data is needed for pkg HOT 2
- features help
- Concept for testing: `add_key_feat` or `key_feat` HOT 1
- Documenting what happens to features when you use functions that return vectors rather than scalars HOT 1
- feat_five_num returns tibble of lists HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from brolgar.