Distance representation
Create Distance representation object
stage.loadFile( "rcsb://1crn" ).then( function( o ){ o.addRepresentation( "cartoon" ); // either give selections (uses first selected atom) ... var atomPair = [ [ "1.CA", "4.CA" ], [ "7.CA", "13.CA" ] ]; // or atom indices var atomPair = [ [ 8, 28 ], [ 173, 121 ] ]; o.addRepresentation( "distance", { atomPair: atomPair } ); stage.autoView(); } );
the structure to be represented
a viewer object
distance representation parameters
Set representation parameters
StructureRepresentation#setSelection
selection string, see {@tutorial selection-language}
this object
Generated using TypeDoc
Distance representation