<div dir="ltr"><div>Hi,</div><div><br></div><div>That should not happen (the length is normally part of the Series representation, independent of the data type or the content or length of the Series). Can you provide a reproducible example? (a piece of code that is self-contained and we can run to reproduce the issue)</div><div><br></div><div>Best,</div><div>Joris<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, 8 Sep 2019 at 22:24, Vicki Brown <<a href="mailto:vlb@cfcl.com">vlb@cfcl.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi -<br>
<br>
I have a dataset:<br>
<br>
<class 'pandas.core.frame.DataFrame'><br>
RangeIndex: 237061 entries, 0 to 237060<br>
Data columns (total 23 columns):<br>
Date 237061 non-null datetime64[ns]<br>
Station Number 237061 non-null object<br>
Depth 237061 non-null float64<br>
...<br>
<br>
For three of the columns, I have calculated value_counts. <br>
For two of those, the result includes the length of the set; for the third, it does not.<br>
<br>
Why not?<br>
<br>
In [1]: dt = wq_df['Date']<br>
dt_counts = dt.value_counts()<br>
<br>
In [2]: st = wq_df['Station Number']<br>
st_counts = st.value_counts()<br>
<br>
In [3]: dp = wq_df['Depth']<br>
dp_counts = dp.value_counts()<br>
<br>
In [4]: dt_counts<br>
<br>
Out[4]: 1969-04-10 21<br>
...<br>
Name: Date, Length: 1172, dtype: int64<br>
<br>
In [5]: st_counts<br>
Out[5]: 18 16622<br>
...<br>
Name: Station Number, dtype: int64<br>
<br>
In [6]: dp_counts<br>
Out[6]: 0.5 1962<br>
...<br>
Name: Depth, Length: 99, dtype: int64<br>
<br>
<br>
<br>
-- Vicki<br>
<br>
Vicki Brown<br>
<a href="http://cfcl.com/vlb" rel="noreferrer" target="_blank">cfcl.com/vlb</a><br>
<br>
<br>
<br>
_______________________________________________<br>
Pandas-dev mailing list<br>
<a href="mailto:Pandas-dev@python.org" target="_blank">Pandas-dev@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/pandas-dev" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/pandas-dev</a><br>
</blockquote></div>