Provide ability to reset index and time index on DataTable via method call
- Ngôn ngữ chính
- Python
- Star
- 155
- Fork
- 24
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
Currently if an index or time index is set on a DataTable they can be reset by calling `dt.index = None` or `dt.time_index = None`. However, this modifies the existing DataTable in place.
If we attempt to call `dt.set_index(None)` to reset the index, an error is raised. We should either update the existing `set_index` and `set_time_index` methods to allow a None value which will reset the index, or add new `reset_index` and `reset_time_index` methods.
To be most consistent with pandas, the approach should be to create new `reset_index` and `reset_time_index` methods on DataTable which return a new DataTable object with the index cleared.
New tests should also be added to test these methods.
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.