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

AttributeError: 'DataFrame' object has no attribute 'as_matrix' #1

Open
prubbens opened this issue Apr 16, 2020 · 4 comments
Open

AttributeError: 'DataFrame' object has no attribute 'as_matrix' #1

prubbens opened this issue Apr 16, 2020 · 4 comments

Comments

@prubbens
Copy link

As Pandas has been updated to v1.0, I think as_matrix should be replaced by .values(). See https://pandas.pydata.org/pandas-docs/version/0.23.4/generated/pandas.DataFrame.as_matrix.html

Otherwise, great to have FlowSOM in Python as well!

@prubbens
Copy link
Author

Correction, was able to fix it by changing it to .to_numpy().

@ghowell2812
Copy link

Hi @prubbens I'm new to this scripting and python work but i'm having the exact same issues - did you change this in the flowsom source code? Which part(s) did you change if you don't mind saying. Thanks

@prubbens
Copy link
Author

prubbens commented May 7, 2020

In lines 74 and 81 of the script flowsomtool.py replace:

   self.tf_matrix = log_data.as_matrix()

by

   self.tf_matrix = log_data.to_numpy() 

and

    self.tf_matrix = self.df.as_matrix()

by

    self.tf_matrix = self.df.to_numpy()

@AlexanderWMacFarlaneIV
Copy link

This is still broken in the release version of the code.

An update would be greatly appreciated.

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

3 participants