Commit 126a316c authored by NOEL Philippe's avatar NOEL Philippe

Fix error in doc in lib.rs

parent cfa5e128
Pipeline #125708 passed with stages
in 1 minute and 31 seconds
......@@ -8,23 +8,34 @@
//!
//! # Examples
//! ```rust
//! use lib3dmol::*;
//! use lib3dmol::parser;
//!
//! fn main() {
//! let my_prot = parse_pdb("tests/tests_file/5jpq.pdb", "5jpq");
//! let my_structure = parser::read_pdb("tests/tests_file/f2.pdb", "Protein f2");
//!
//! println!("Prot : {} \nn chain: {}\nn res: {}\nn atom: {}",
//! my_prot.name, my_prot.get_number_chain(),
//! my_prot.get_number_residue(),
//! my_prot.get_number_atom());
//! println!(
//! "Structure name: {}
//! Number of chain: {}
//! Number of residue: {}
//! Number of atom: {}",
//! my_structure.name,
//! my_structure.get_chain_number(),
//! my_structure.get_residue_number(),
//! my_structure.get_atom_number()
//! );
//!
//! println!("Reduce protein");
//! // Now we will extract the backbone
//!
//! let chain_a = my_prot.select_atoms("chain a").unwrap();
//! println!("Prot : {} \nn chain: {}\nn res: {}\nn atom: {}",
//! chain_a.name, chain_a.get_number_chain(),
//! chain_a.get_number_residue(),
//! chain_a.get_number_atom());
//! let backbone = my_structure.select_atoms("backbone").unwrap();
//!
//! println!(
//! "Number of chain: {}
//! Number of residue: {}
//! Number of atom: {}",
//! backbone.get_chain_number(),
//! backbone.get_residue_number(),
//! backbone.get_atom_number()
//! );
//! }
//! ```
#[macro_use]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment