INCATools / INCATools/ontology-access-kit
statistics --compare-with output is opposite to expectation
- Dominant language
- Python
- Stars
- 198
- Forks
- 35
- Avg merge
- 3d 4h
- Merged PRs (30d)
- 1
Description
Trying to use `runoak statistics --compare-with`. I feel like the comparison output is backwards. First I try a diff command:
```
runoak -i simpleobo:go-lastrelease.obo diff -X simpleobo:go.obo --group-by-property oio:hasOBONamespace -o oakdiff2 --statistics
```
output includes:
```yaml
molecular_function:
MappingCreation: 1467
NodeRename: 61
NodeTextDefinitionChange: 99
RemoveMapping: 498
ClassCreation: 13
```
This matches my expectation, since with any diff usually the "previous" version is the left. Also the documentation says "produce a list of Changes that are required to go from the main input ontology (–input) to the other ontology (–other-ontology, or -X)." Sounds right.
If I run the statistics command:
```
runoak -i simpleobo:go.obo statistics --group-by-obo-namespace --compare-with simpleobo:go-lastrelease.obo
```
the output includes:
```yaml
molecular_function:
change_summary:
RemoveMapping: 1464
EdgeDeletion: 41
EdgeCreation: 37
NodeTextDefinitionChange: 99
NodeUnobsoletion: 8
NodeRename: 61
MappingCreation: 498
NodeDeletion: 13
```
So the first diff said I created 13 classes (correct) but this compare-with sees it as deleting 13 classes. I would not expect that to be the intent of the compare-with option for statistics. I wouldn't think you'd be running `statistics` to get info on the old version. I want to get info on the current version, and a summary of changes since the last version.
Contributor guide
Research direction
Start by reproducing the two commands shown for runoak statistics --compare-with and the diff command, then compare their change directions for class creation and mapping changes. Trace the statistics compare-with entry point and verify the output describes changes from the last release to the current ontology, matching the documented direction and the diff results.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100