ENH: add way to check for sparse data (#26706)
- [X] closes #26706 
- [x] tests added / passed
- [X] passes `black pandas`
- [x] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [X] whatsnew entry

> it seems that other `is_...` ones we have are attributes (at least the ones in Series, not sure if we have public ones in other places), so we should probably be consistent with that.

Actually, looking a bit further, we have also `is_..` methods/attributes on Index, and there `is_all_dates`, `is_unique`, `is_monotonic` and some others are attributes, but `is_boolean/categorical/floating/integer/numeric/...` are methods ... So in that case maybe rather keep as a method? -1 as already indicated as this is unecessary api bloat 

we don’t have is_float or is_integer as properties (they already exist as functions) Jeff, did you see this is on the `.sparse` accessor? (we don't have a float or integer accessor, so any comparison isn't really correct) So it does not add to the top-level DataFrame namespace.

On the issue (https://github.com/pandas-dev/pandas/issues/26706) you mentioned `select_dtypes` as what should be used, but @TomAugspurger explained how that is not an alternative. Please respond to the specifics if you do not agree with that. @jorisvandenbossche your original issue shows this works just fine with .apply
so -1 on any expansion here; even in the accessor this doesn’t make any sense (even less sense)

we already have multiple ways of selectimg dtypes and i don’t see any justification  I think this makes sense to add.

Slight preference for it being a property, rather than a method call, but either works. Should I update the PR to make it a property?  Probably wait till we come to an agreement.

My argument for property is that this is essentially statically known
(though there is a bit of computation).

On Wed, Sep 11, 2019 at 2:26 AM SdgJlbl <notifications@github.com> wrote:

> Should I update the PR to make it a property?
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <https://github.com/pandas-dev/pandas/pull/28314?email_source=notifications&email_token=AAKAOIXP6ASEAA6MTG4AJH3QJCMSFA5CNFSM4IUIVVAKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD6NRNRI#issuecomment-530257605>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AAKAOIUIW5H2AOFCUZHVJNLQJCMSFANCNFSM4IUIVVAA>
> .
>
 > My argument for property is that this is essentially statically known
(though there is a bit of computation).

That's a good argument (the `Index.is_boolean()/is_numeric()/...` which are methods check the inferred type, so with potentially a lot of computation). I am fine with going for a property then. I don't believe there is a consensus on this change so closing for now to clear queue; can pick reopen if one is reached later