cheminfo / cheminfo/cheminfo-types
How to deal with values with errors
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2
- Forks
- 3
- Avg merge
- 1m
- Merged PRs (30d)
- 1
Description
How to deal with values that may have errors ?
Should we allow that a value has error directly in the QuantityWithUnit or should it be another type ?
```ts
export interface QuantityWithUnit {
value: number|ValueWithError;
unitText: string;
unitCode: string|URL;
}
export interface ValueWithError {
value: number;
sd: number;
}
```
What would be the consequence ? I guess that each time we reuse this kind of object we would have to throw if ever we would not deal with a ValueWithError
Contributor guide
No contributing guide indexed for this repository
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 with the QuantityWithUnit and ValueWithError interface examples in the issue and review the three existing comments. Resolve whether errors belong in QuantityWithUnit or a separate type, and document the consequences for every consumer; the work is done when the representation and handling expectations are agreed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100