Closed tswsxk closed 2 months ago
Thank you to report this issue, if I understand correctly you should have only nan values in your columns, is it right ? Actually the code should not bug if you have a column with just some nan values in it. Can you tell us why you have such a column used in your model ? We don't see the use case. In any case we will look at your PR and see the best way to tackle this issue.
Hi, there. Usually, the nan columns could be removed during data preprocessing. However, in my case, the data is several time series and one column contains only nan values before a specific date. Thus, when I conduct experiments, where I need to split the data according to dates for training. However, the all-nan values in this column before a specific date cause this error.
It has been fixed with the version 2.6.0 of shapash (https://github.com/MAIF/shapash/pull/553)
When using shapash along with the following codes:
it will call the init_app in SmartApp class where the following codes are used to calculate the std of a certain column (line 192 - 199):
However, when a column with nan values, std will be nan and execute the following line:
and result in ValueError:
Python version : python3.10
Shapash version : shapash-2.5.0
Operating System : CentOS Linux release 8.2.2.2004