Support .reindex with DataArrays and Dataset as indexers
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 4.2k
- Forks
- 1.4k
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 14
Description
I want to select data using Dataset as indexers but fill missing with NaN, but I found that the .sel method should match all the indices. After searching the doc, I get that the method .reindex can allow some indices that not match and fill them with NaN. But unfortunately the .reindex does not support DataArrays and Dataset as indexers.
I think the best way to deal this situation is adding this support to .reindex method, so we can keep maximum compatibility and make less implication changed, shall we?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing the existing .reindex and .sel behavior for DataArray and Dataset indexers, using the issue's missing-index and NaN-filling scenario as the acceptance case. Done means .reindex accepts these indexers, permits unmatched indices, and fills missing values with NaN while preserving compatibility with existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100