Rosetta 3.5
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
protocols
comparative_modeling
features
TorsionFeature.cc
Go to the documentation of this file.
1
// -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2
// vi: set ts=2 noet:
3
//
4
// (c) Copyright Rosetta Commons Member Institutions.
5
// (c) This file is part of the Rosetta software suite and is made available under license.
6
// (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
7
// (c) For more information, see http://www.rosettacommons.org. Questions about this can be
8
// (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
9
10
/// @file protocols/comparative_modeling/TorsionFeature.cc
11
/// @brief
12
/// @author James Thompson
13
14
#include <
core/types.hh
>
15
#include <
core/pose/Pose.hh
>
16
// AUTO-REMOVED #include <utility/vector1.hh>
17
18
#include <
protocols/comparative_modeling/features/ResidueFeature.hh
>
19
#include <
protocols/comparative_modeling/features/TorsionFeature.hh
>
20
#include <
protocols/comparative_modeling/features/ResidueFeature.fwd.hh
>
21
22
#include <
core/conformation/Residue.hh
>
23
24
#include <utility/vector1.hh>
25
26
27
namespace
protocols {
28
namespace
comparative_modeling {
29
namespace
features {
30
31
TorsionFeature::TorsionFeature
() :
32
torsion_bin_(
INVALID
)
33
{}
34
35
TorsionFeature::TorsionFeature
(
TorsionFeature
const
& other ) :
36
ResidueFeature
(),
37
torsion_bin_( other.torsion_bin() )
38
{}
39
40
TorsionFeature::TorsionFeature
(
TorsionBin
bin ) :
41
torsion_bin_( bin )
42
{}
43
44
utility::vector1< ResidueFeatureOP >
45
TorsionFeature::values_from_pose
(
core::pose::Pose
& pose )
const
{
46
using
core::Real
;
47
using
utility::vector1
;
48
vector1< TorsionFeatureOP >
features;
49
50
for
(
Size
ii = 1; ii <= pose.
total_residue
(); ++ii ) {
51
vector1< Real >
const
& torsions( pose.
residue
(ii).
mainchain_torsions
() );
52
Real
phi
= torsions[1];
53
Real
psi
= torsions[2];
54
Real
omega
= torsions[3];
55
features.push_back(
56
new
TorsionFeature
(
torsion2big_bin
( phi, psi, omega ) )
57
);
58
}
59
60
return
features;
61
}
62
63
std::string
TorsionFeature::type
()
const
{
64
return
"torsion_bin"
;
65
}
66
67
ResidueFeatureOP
TorsionFeature::clone
()
const
{
68
TorsionFeatureOP
copy(
new
TorsionFeature
( *
this
) );
69
return
copy;
70
}
71
72
TorsionBin
TorsionFeature::torsion_bin
()
const
{
73
return
torsion_bin_
;
74
}
75
76
TorsionBin
77
TorsionFeature::torsion2big_bin
(
78
core::Real
const
phi
,
79
core::Real
const
psi
,
80
core::Real
const
omega
81
)
82
{
83
if
( std::abs( omega ) < 90.0 ) {
84
return
O
;
// cis-omega
85
}
else
if
( phi >= 0.0 ) {
86
if
( -100.0 < psi && psi <= 100.0 ) {
87
return
G
;
// alpha-L
88
}
else
{
89
return
E
;
// E
90
}
91
}
else
{
92
if
( -125.0 < psi && psi <= 50.0 ) {
93
return
A
;
// helical
94
}
else
{
95
return
B
;
// extended
96
}
97
}
98
return
X
;
99
}
100
101
}
// features
102
}
// comparative_modeling
103
}
// protocols
Generated on Sat Jun 1 2013 11:45:27 for Rosetta 3.5 by
1.8.4