-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modernize chimera script generation (#18)
Old hacky behavior is deprecated in favor of something saner. Also leverages the new latest-version alphafold file machinery.
- Loading branch information
Showing
5 changed files
with
64 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
function markers(modelnum::Integer, positions::AbstractVector{<:AbstractVector{<:Real}}, radius::Real, color) | ||
Base.depwarn("`markers` is deprecated, use `marker.(modelnum, positions, radius, color)` instead", :markers) | ||
return [marker(modelnum, pos, radius, color) for pos in positions] | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
@testset "Deprecated" begin | ||
@info "Testing deprecated functions (warnings are expected)" | ||
@test only(GPCRAnalysis.markers(2, [Coordinates(5, 4, 3)], 0.5, "blue")) == "marker #2 position 5.0,4.0,3.0 radius 0.5 color blue" | ||
dot = GPCRAnalysis.marker(2, Coordinates(5, 4, 3), 0.5, "blue") | ||
tmpfile = tempname() * ".cxc" | ||
chimerax_script(tmpfile, ["align_ABCD.pdb", "align_EFGH.pdb"], [[5, 10, 15], [7, 11]]; extras=[dot]) | ||
script = read(tmpfile, String) | ||
@test !occursin("matchmaker #2-2 to #1", script) | ||
@test occursin("marker #2 position 5.0,4.0,3.0 radius 0.5 color blue", script) | ||
rm(tmpfile) | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters