Unexpected output th.stats.std
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 18
- Forks
- 10
- PR merge metrics
- No merged PRs in 30d
Description
There is an issue with the th.stats.std function where single profiled thicket results in Nan's value due to pandas use of sample standard deviation instead of population standard deviation.
A way to get around this issue is to use `lambda x: np.std(x)` in the aggregate function of th.stats.std.
i.e `df = thicket.dataframe[columns].reset_index().groupby("node").agg(lambda x: np.std(x))`
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 at the th.stats.std entry point and inspect how its aggregate function handles a single profiled thicket result. Reproduce the NaN output, compare the current sample-standard-deviation behavior with population standard deviation, and verify that the result is finite for the single-profile case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- numpy, pandas, python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100