0

I have problems importing plot_decision_regions from mlxtend.plotting.

I have correctly installed mlxtend and I can import it in python3 without problems.

from mlxtend.plotting import plot_decision_regions Traceback (most recent call last): File "", line 1, in File "/home/marianna/.local/lib/python3.5/site-packages/mlxtend/plotting/init.py", line 15, in from .heatmap import heatmap File "/home/marianna/.local/lib/python3.5/site-packages/mlxtend/plotting/heatmap.py", line 74 raise AssertionError(f'len(row_names) (got {len(row_names)})' ^ SyntaxError: invalid syntax

mrn314159
  • 11
  • 5

1 Answers1

0

I had the same error, just upgrade your python version to 3.7 the read error is in the file of mlxtend.plotting.heatmap.py where they use f-prefix for formating, a 3.7 feature.

conda install -c anaconda python=3.7