Skip to content

Conversation

sinhrks
Copy link
Member

@sinhrks sinhrks commented May 12, 2016

Fixed following bugs. These makes MultiIndex repr work.

orig = pd.Series([1, np.nan, np.nan, 3, np.nan], index=idx)
sparse = orig.to_sparse()
sparse['A']    
# IndexError: Out of bounds access
# the result must have MultiIndex
sparse.loc['A':]
# (A, 0)    1.0
# (A, 1)    NaN
# (B, 0)    NaN
# (C, 0)    3.0
# (C, 1)    NaN
# dtype: float64
# BlockIndex
# Block locations: array([0, 3], dtype=int32)
# Block lengths: array([1, 1], dtype=int32)

@sinhrks sinhrks added Bug Indexing Related to indexing on series/frames, not to indexes themselves Output-Formatting __repr__ of pandas objects, to_string Sparse Sparse Data Type labels May 12, 2016
@sinhrks sinhrks added this to the 0.18.2 milestone May 12, 2016
@kawochen kawochen mentioned this pull request May 13, 2016
18 tasks
@codecov-io
Copy link

codecov-io commented May 13, 2016

Current coverage is 84.12%

Merging #13163 into master will decrease coverage by -<.01%

@@             master     #13163   diff @@
==========================================
  Files           138        138          
  Lines         50380      50380          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          42380      42378     -2   
- Misses         8000       8002     +2   
  Partials          0          0          
  1. File ...das/sparse/series.py was modified. more
    • Misses +1
    • Partials 0
    • Hits -1

Powered by Codecov. Last updated by 4de83d2...eb24102

@jreback jreback closed this in 00d4ec3 May 13, 2016
@jreback
Copy link
Contributor

jreback commented May 13, 2016

thanks @sinhrks

@sinhrks sinhrks deleted the sparse_multi branch May 13, 2016 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Indexing Related to indexing on series/frames, not to indexes themselves Output-Formatting __repr__ of pandas objects, to_string Sparse Sparse Data Type
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SparseSeries throws a ValueError exception when printing large arrays
3 participants