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

pandas as_matrix deprecation #33

Open
imanyakin opened this issue Jun 28, 2022 · 2 comments
Open

pandas as_matrix deprecation #33

imanyakin opened this issue Jun 28, 2022 · 2 comments

Comments

@imanyakin
Copy link

imanyakin commented Jun 28, 2022

Trying to run MCS analysis, but gt complains:

'DataFrame' object has no attribute 'as_matrix'

This appears to have been deprecated since 0.23.0.

  • There are only two instances of as_matrix use in pygcam/mcs/sensitivity.py
  • seems like they can be fixed with relative ease:

'bounds' : data.as_matrix(columns=['low','high']), ->
'bounds' : data[['low','high']].to_numpy(),

self.results = self.resultsDF[resultName].as_matrix() ->
self.results = self.resultsDF[resultName].to_numpy()

@imanyakin imanyakin changed the title pandas as_matrix deprication pandas as_matrix deprecation Jun 28, 2022
@rjplevin
Copy link
Collaborator

As you have discovered, the entire set of code related to SALib is very outdated. I haven't used it or worked on it in years. I cannot recommend using anything other than the default Monte Carlo methods at this time.

Please understand that I have no funding for further work on pygcam, so the only features that get added at this point are those that I require for my own work. I use pygcam in all my ongoing work with GCAM, but I do not use every feature, and I work only on the Mac and Linux platforms. I rarely do testing on Windows. My current work involves a custom version based on GCAMv5.3, and I haven't had opportunity to use 6.0 yet.

I'd be happy to develop / complete new features if funding were available.

@imanyakin
Copy link
Author

Hi Richard, yes of course - sorry I didn't mean to 'create work'

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