Home > other >  There is an error code only integer scalar arrays can be converted to a scalar index small white for
There is an error code only integer scalar arrays can be converted to a scalar index small white for

Time:10-06




Df [' NO2] [3]
In
TypeError Traceback (the most recent call last)

- & gt; 1 df [' NO2] [3]

C: \ ProgramData \ Anaconda3 \ lib \ site - packages, pandas, core, frame, py in the __getitem__ (self key)
2956 if the self. The columns. Nlevels & gt; 1:
2957 the return of the self. _getitem_multilevel (key)
- & gt; 2958 the return of the self. _get_item_cache (key)
2959
2960 # Do we have a slicer (on rows)?

C: \ ProgramData \ Anaconda3 \ lib \ site - packages, pandas, core, generic. Py in _get_item_cache (self, item)
3268 res=cache. Get (item)
3269 if res is None:
- & gt; 3270 values=self. _data while forming. The get (item)
3271 res=self. _box_item_values (item, values)
3272 cache [items]=res

C: \ ProgramData \ Anaconda3 \ lib \ site - packages, pandas, core, internals \ managers py in the get (self, item)
958 raise ValueError (" always label index with a null key ")
959
- & gt; 960 the return of the self. Iget struck in (loc)
961 else:
962

C: \ ProgramData \ Anaconda3 \ lib \ site - packages, pandas, core, internals \ managers py in iget struck in (self, I)
975 Otherwise return as a ndarray
976 ", "
"- & gt; 977 block=self. Blocks [self _blknos [I]]
978 values=block. Iget struck in (self _blklocs [I])
979 if values. Ndim!=1:

TypeError: only integer scalar arrays can be converted to a scalar index
  • Related