Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
openstructure
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
schwede
openstructure
Commits
2cfc42c1
Commit
2cfc42c1
authored
13 years ago
by
Valerio Mariani
Browse files
Options
Downloads
Patches
Plain Diff
Added coverage resport
parent
6ea69ef7
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
modules/mol/alg/src/ldt.cc
+22
-0
22 additions, 0 deletions
modules/mol/alg/src/ldt.cc
modules/mol/alg/src/local_dist_test.cc
+2
-2
2 additions, 2 deletions
modules/mol/alg/src/local_dist_test.cc
with
24 additions
and
2 deletions
modules/mol/alg/src/ldt.cc
+
22
−
0
View file @
2cfc42c1
...
@@ -27,6 +27,7 @@
...
@@ -27,6 +27,7 @@
#include
<ost/io/mol/pdb_reader.hh>
#include
<ost/io/mol/pdb_reader.hh>
#include
<ost/io/io_exception.hh>
#include
<ost/io/io_exception.hh>
#include
<ost/conop/conop.hh>
#include
<ost/conop/conop.hh>
#include
<ost/conop/amino_acids.hh>
#include
<ost/mol/iterator.hh>
#include
<ost/mol/iterator.hh>
#include
<ost/platform.hh>
#include
<ost/platform.hh>
#include
<ost/log.hh>
#include
<ost/log.hh>
...
@@ -75,6 +76,25 @@ void usage()
...
@@ -75,6 +76,25 @@ void usage()
std
::
cerr
<<
" -e print version"
<<
std
::
endl
;
std
::
cerr
<<
" -e print version"
<<
std
::
endl
;
}
}
std
::
pair
<
int
,
int
>
compute_coverage
(
const
EntityView
&
v
,
const
GlobalDistanceList
&
glob_dist_list
)
{
int
second
=
0
;
int
first
=
0
;
ChainView
vchain
=
v
.
GetChainList
()[
0
];
for
(
std
::
vector
<
ResidueDistanceList
>::
const_iterator
i
=
glob_dist_list
.
begin
();
i
!=
glob_dist_list
.
end
();
++
i
)
{
ResNum
rnum
=
(
*
i
)[
0
].
GetFirstAtom
().
GetResNum
();
String
rname
=
(
*
i
)[
0
].
GetFirstAtom
().
GetResidueName
();
if
(
ost
::
conop
::
ResidueNameToOneLetterCode
(
rname
)
!=
'X'
)
{
second
++
;
if
(
vchain
.
FindResidue
(
rnum
))
{
first
++
;
}
}
}
return
std
::
make_pair
<
int
,
int
>
(
first
,
second
);
}
int
main
(
int
argc
,
char
**
argv
)
int
main
(
int
argc
,
char
**
argv
)
{
{
String
version
=
"Beta - 2012-01-17"
;
String
version
=
"Beta - 2012-01-17"
;
...
@@ -236,9 +256,11 @@ int main (int argc, char **argv)
...
@@ -236,9 +256,11 @@ int main (int argc, char **argv)
}
}
GlobalDistanceList
glob_dist_list
=
CreateDistanceList
(
ref_view
,
radius
);
GlobalDistanceList
glob_dist_list
=
CreateDistanceList
(
ref_view
,
radius
);
std
::
pair
<
int
,
int
>
cov
=
compute_coverage
(
v
,
glob_dist_list
);
Real
ldt
=
LDTHA
(
v
,
glob_dist_list
);
Real
ldt
=
LDTHA
(
v
,
glob_dist_list
);
std
::
cout
<<
"File: "
<<
files
[
i
]
<<
std
::
endl
;
std
::
cout
<<
"File: "
<<
files
[
i
]
<<
std
::
endl
;
std
::
cout
<<
"Coverage: "
<<
(
float
(
cov
.
first
)
/
float
(
cov
.
second
))
<<
" ("
<<
cov
.
first
<<
" out of "
<<
cov
.
second
<<
" residues)"
<<
std
::
endl
;
std
::
cout
<<
"Global LDT score: "
<<
ldt
<<
std
::
endl
;
std
::
cout
<<
"Global LDT score: "
<<
ldt
<<
std
::
endl
;
std
::
cout
<<
"Local LDT Score:"
<<
std
::
endl
;
std
::
cout
<<
"Local LDT Score:"
<<
std
::
endl
;
std
::
cout
<<
"Chain
\t
ResName
\t
ResNum
\t
Score"
<<
std
::
endl
;
std
::
cout
<<
"Chain
\t
ResName
\t
ResNum
\t
Score"
<<
std
::
endl
;
...
...
This diff is collapsed.
Click to expand it.
modules/mol/alg/src/local_dist_test.cc
+
2
−
2
View file @
2cfc42c1
#include
<ost/log.hh>
#include
<ost/log.hh>
#include
<ost/mol/mol.hh>
#include
<ost/mol/mol.hh>
#include
<ost/conop/amino_acids.hh>
#include
"local_dist_test.hh"
#include
"local_dist_test.hh"
#include
<boost/concept_check.hpp>
#include
<boost/concept_check.hpp>
...
@@ -259,8 +260,7 @@ GlobalDistanceList CreateDistanceList(const EntityView& ref,Real max_dist)
...
@@ -259,8 +260,7 @@ GlobalDistanceList CreateDistanceList(const EntityView& ref,Real max_dist)
ResidueViewList
ref_residues
=
ref
.
GetChainList
()[
0
].
GetResidueList
();
ResidueViewList
ref_residues
=
ref
.
GetChainList
()[
0
].
GetResidueList
();
for
(
ResidueViewList
::
iterator
i
=
ref_residues
.
begin
(),
e
=
ref_residues
.
end
();
i
!=
e
;
++
i
)
{
for
(
ResidueViewList
::
iterator
i
=
ref_residues
.
begin
(),
e
=
ref_residues
.
end
();
i
!=
e
;
++
i
)
{
ResidueView
rview
=
(
*
i
);
ResidueView
rview
=
(
*
i
);
//# if (rview.IsPeptideLinking()) {
if
(
ost
::
conop
::
ResidueNameToOneLetterCode
(
rview
.
GetName
())
!=
'X'
)
{
if
(
true
)
{
ResidueDistanceList
res_dist_list
;
ResidueDistanceList
res_dist_list
;
AtomViewList
ref_atoms
=
(
*
i
).
GetAtomList
();
AtomViewList
ref_atoms
=
(
*
i
).
GetAtomList
();
AtomViewList
within
;
AtomViewList
within
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment