Skip to content

Commit

Permalink
Add check for locus
Browse files Browse the repository at this point in the history
This always assumes a Center locus when the bounds are not explicitely hit.
We might want to check for the actual center, but this might become problematic for time bounds.
  • Loading branch information
felixcremer committed May 15, 2024
1 parent 342d9a2 commit 0b2bc8d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/sources/commondatamodel.jl
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,14 @@ function _cdmlookup(
else
boundskey = var.attrib["bounds"]
boundsmatrix = Array(ds[boundskey])
Explicit(boundsmatrix), Intervals(Center())
locus = if all(boundsmatrix[1,:] .== index)
Start()
elseif all(boundsmatrix[2,:] .== index)
End()
else
Center()
end
Explicit(boundsmatrix), Intervals(locus)
end
end

Expand Down

0 comments on commit 0b2bc8d

Please sign in to comment.