-
Notifications
You must be signed in to change notification settings - Fork 7
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
Add waffle representation & partial plot #28
Conversation
@@ -10,6 +10,15 @@ | |||
from openalea.mtg.algo import orders | |||
from openalea.mtg import stat, algo, traversal | |||
|
|||
from pandas.core.groupby.groupby import DataError |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Put first import of standard Python libraries.
Then 3rd party libs.
Then openalea ones (mtg & co)
src/openalea/strawberry/analysis.py
Outdated
|
||
def stage(vid, g): | ||
_stage = g.property('Stade') | ||
return next(iter(list(_stage[cid] for cid in g.components(vid) if cid in _stage)), None) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do not get it.
Why not just take the first element?
You do not need to convert it to a list.
And you can use components_iter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent! Thanks
The waffle dataframe creation from extracted data works.
The plot partially works: axes & grid spacing are not correctly displayed.
Partial fix of issue #27