From d5be1c7cc72c48f00fd116c68fa25c87d7b5211c Mon Sep 17 00:00:00 2001 From: Joe Greener Date: Fri, 21 Jun 2024 13:53:44 +0100 Subject: [PATCH] BioStructures.jl compat --- Project.toml | 2 +- src/protein/pdb.jl | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Project.toml b/Project.toml index 37dfbc1..8c9db0c 100644 --- a/Project.toml +++ b/Project.toml @@ -17,7 +17,7 @@ Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" ZygoteIdealizationExt = ["Zygote"] [compat] -BioStructures = "3" +BioStructures = "4" LinearAlgebra = "1" PrecompileTools = "1" Rotations = "1" diff --git a/src/protein/pdb.jl b/src/protein/pdb.jl index 0eba779..9fb8184 100644 --- a/src/protein/pdb.jl +++ b/src/protein/pdb.jl @@ -53,7 +53,7 @@ function Protein.Chain(chain::BioStructures.Chain; res_selector=backboneselector return Protein.Chain(residues) end -function chains(struc::BioStructures.ProteinStructure; res_selector=backboneselector) +function chains(struc::BioStructures.MolecularStructure; res_selector=backboneselector) chains = Protein.Chain[] for model in struc, chain in model isempty(chain) || push!(chains, Protein.Chain(chain, res_selector=res_selector)) @@ -68,7 +68,7 @@ Loads a protein (represented as a `Vector{Protein.Chain}`) from a PDB file. Assumes that each residue starts with three atoms: N, CA, C. """ function readpdb(pdbfile::String) - struc = read(pdbfile, BioStructures.PDB) + struc = read(pdbfile, BioStructures.PDBFormat) return chains(struc) end