Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fill_up() #114

Closed
coolbutuseless opened this issue Sep 16, 2015 · 2 comments
Closed

fill_up() #114

coolbutuseless opened this issue Sep 16, 2015 · 2 comments

Comments

@coolbutuseless
Copy link
Contributor

Feature request: A complementary function to fill() (or even just a flag), that fills upwards.

I currently do this with a rev(zoo::lacf(rev(x))).

@hadley
Copy link
Member

hadley commented Sep 16, 2015

Can you provide an example where you see this sort of data?

@coolbutuseless
Copy link
Contributor Author

I understand that the fill down is much more common - especially for manually constructed data (like excel spreadsheets) where people enter a value once in a column on the assumption that it is unchanged until the next entry.

I see lots of data - usually after merging - where I want all values filled, but there's no guarantee that the first row contains a value.

As an example: drug trial data where weight (or other demographic data) might be measured on the second visit, but not the first. After merging data sets for analysis, the weight needs to be copied up and down within each subject.

I'm probably an outlier here, and fully understand if this feature is not a priority. Thanks.

@hadley hadley closed this as completed in 37108ce Dec 30, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants