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

Mathematical operations for DataFrames #346

Closed
nfoti opened this issue Aug 14, 2013 · 1 comment
Closed

Mathematical operations for DataFrames #346

nfoti opened this issue Aug 14, 2013 · 1 comment

Comments

@nfoti
Copy link
Contributor

nfoti commented Aug 14, 2013

Common math operations that work along dimensions of Arrays would be useful for DataFrames (and DataArrays as discussed in issue #325). The use case I envision is there are many numerical columns and some categorical columns, and say we want to compute the average of the numerical columns. It would be great to be able to say df["mean_col"] = mean(df[:,numeric_colinds], 2, skipna=true) without having to convert to a DataMatrix first. If someone tries to take the mean of something that doesn't make sense an error can be thrown.

If people think this is useful I'm willing to take a stab at it. I prefer the mean(df, dim, skipna) interface to rowmeans and colmeans to stay consistent with the rest of Julia but if others prefer the R names I can go along with that.

Thanks.

@garborg
Copy link
Contributor

garborg commented Jan 12, 2015

Closing as ensuing discussions have also landed on 'no' to treating DataFrames this way.

@garborg garborg closed this as completed Jan 12, 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