0

What does this comma imply?

Here's the relevant lines in my code... data = pd.DataFrame(data, dtype = int16) data = data.values test = data[4] print("Shape: " + str(test.shape)) Shape: (4087L,) Why is there a comma after the L and what does that mean about how my data is stored?

18th May 2017, 10:09 PM
Edward Furey
Edward Furey - avatar
1 Answer
+ 1
Oh, ok I found the answer. I did a head() and got an error that numpy.ndarray didn't have attribute head. So I googled numpy array comma and found that it's shape is always a tuple and you always get a comma after a 1D tuple. Live and learn eh. :)
18th May 2017, 10:16 PM
Edward Furey
Edward Furey - avatar