>>> pd.SparseSeries([False, True], dtype=bool)[[0, 1]]
0    0.0
1    1.0
dtype: float64
BlockIndex
Block locations: array([1], dtype=int32)
Block lengths: array([1], dtype=int32)

Expected output

0    False
1    True
dtype: bool
BlockIndex
Block locations: array([1], dtype=int32)
Block lengths: array([1], dtype=int32)

Output of pd.versions()

pandas: 0.18.1

should alone be relevant.

Apologies I've not checked if this is fixed by #13849 or elsewhere. Just passing on issues from https://github.com/scikit-learn/scikit-learn/issues/7352.

Comment From: jreback

in master/0.19.0 (rc1 comes out this week)

http://pandas-docs.github.io/pandas-docs-travis/whatsnew.html#sparse-changes

In [1]: pd.SparseSeries([False, True], dtype=bool)[[0, 1]]
Out[1]: 
0    False
1     True
dtype: bool
BlockIndex
Block locations: array([1], dtype=int32)
Block lengths: array([1], dtype=int32)

Comment From: jnothman

Great.

On 7 September 2016 at 10:15, Jeff Reback notifications@github.com wrote:

in master/0.19.0 (rc1 comes out this week)

In [1]: pd.SparseSeries([False, True], dtype=bool)[[0, 1]] Out[1]: 0 False 1 True dtype: bool BlockIndex Block locations: array([1], dtype=int32) Block lengths: array([1], dtype=int32)

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pydata/pandas/issues/14166#issuecomment-245136113, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEz6_YBbzib9rBG3whtH5tqZh0nnbAoks5qngI1gaJpZM4J2ZaC .