wdecoster / NanoPlot

Plotting scripts for long read sequencing data
http://nanoplot.bioinf.be
MIT License
432 stars 47 forks source link

ValueError: `bins` should be a positive integer #198

Closed MMS413 closed 4 years ago

MMS413 commented 4 years ago

Hello, I am using Python 3.7 via Spyder 3.3.6 (as part of the Anaconda suite) as part of a class I'm currently taking. (I'm new to Python, so I apologize in advance if the answer to resolving this error seems obvious.) How do I move past this error?

import pandas import numpy import seaborn import matplotlib.pyplot as plt data = pandas.read_csv('classdata_pds.csv', low_memory=False)

sub2['PACKSPERMONTH']=sub2['NUMCIGMO_EST'] / 20 c12 = sub2.groupby('PACKSPERMONTH').size() print(c12)

sub2['PACKCATEGORY']=pandas.cut(sub2.PACKSPERMONTH, 0, 5, 10, 20, 30, 147)

# produced ValueError: bins should be a positive integer.

Thank you

wdecoster commented 4 years ago

How is this related to NanoPlot?