Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
melodic
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
FSL
melodic
Commits
fef0d7d3
Commit
fef0d7d3
authored
13 years ago
by
Christian Beckmann
Browse files
Options
Downloads
Patches
Plain Diff
Concat for unequal number of volumes
parent
82c179f9
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
meldata.cc
+13
-2
13 additions, 2 deletions
meldata.cc
meldata.h
+4
-0
4 additions, 0 deletions
meldata.h
melodic.cc
+3
-3
3 additions, 3 deletions
melodic.cc
melreport.cc
+2
-0
2 additions, 0 deletions
melreport.cc
with
22 additions
and
5 deletions
meldata.cc
+
13
−
2
View file @
fef0d7d3
...
...
@@ -139,10 +139,13 @@ namespace Melodic{
void
MelodicData
::
set_TSmode
()
{
Matrix
tmp
,
tmpT
,
tmpS
,
tmpT2
,
tmpS2
,
tmpT3
;
tmp
=
expand_dimred
(
mixMatrix
);
tmpT
=
zeros
(
tmp
.
Nrows
()
/
numfiles
,
tmp
.
Ncols
());
tmpS
=
zeros
(
numfiles
,
tmp
.
Ncols
());
explained_var
=
krfact
(
tmp
,
tmpT
,
tmpS
);
if
(
opts
.
approach
.
value
()
==
string
(
"tica"
)){
explained_var
=
krfact
(
tmp
,
tmpT
,
tmpS
);
outMsize
(
"tmp"
,
tmp
);
outMsize
(
"tmpT"
,
tmpT
);
outMsize
(
"tmpS"
,
tmpS
);
...
...
@@ -164,7 +167,7 @@ namespace Melodic{
add_Smodes
(
tmpS2
);
}
// }
//add GLM OLS fit
if
(
Tdes
.
Storage
()){
Matrix
alltcs
=
Tmodes
.
at
(
0
).
Column
(
1
);
...
...
@@ -180,6 +183,14 @@ namespace Melodic{
if
((
alltcs
.
Nrows
()
==
Sdes
.
Nrows
())
&&
(
Sdes
.
Nrows
()
>
Sdes
.
Ncols
()
&&
alltcs
.
Nrows
()
>
2
))
glmS
.
olsfit
(
alltcs
,
Sdes
,
Scon
);
}
}
// else{
// add_Tmodes(tmp);
// }
dbgmsg
(
string
(
"END: set_TSmode"
));
}
void
MelodicData
::
setup
()
...
...
This diff is collapsed.
Click to expand it.
meldata.h
+
4
−
0
View file @
fef0d7d3
...
...
@@ -76,20 +76,24 @@ namespace Melodic{
inline
Matrix
&
get_Smodes
(
int
what
)
{
return
Smodes
.
at
(
what
);}
inline
void
add_Smodes
(
Matrix
&
Arg
)
{
Smodes
.
push_back
(
Arg
);}
inline
void
save_Smodes
(){
if
(
Smodes
.
size
()
>
0
){
Matrix
tmp
=
Smodes
.
at
(
0
);
for
(
unsigned
int
ctr
=
1
;
ctr
<
Smodes
.
size
();
ctr
++
)
tmp
|=
Smodes
.
at
(
ctr
);
saveascii
(
tmp
,
opts
.
outputfname
.
value
()
+
"_Smodes"
);
}
}
inline
vector
<
Matrix
>&
get_Tmodes
()
{
return
Tmodes
;}
inline
Matrix
&
get_Tmodes
(
int
what
)
{
return
Tmodes
.
at
(
what
);}
inline
void
add_Tmodes
(
Matrix
&
Arg
)
{
Tmodes
.
push_back
(
Arg
);}
inline
void
save_Tmodes
(){
if
(
Tmodes
.
size
()
>
0
){
Matrix
tmp
=
Tmodes
.
at
(
0
);
for
(
unsigned
int
ctr
=
1
;
ctr
<
Tmodes
.
size
();
ctr
++
)
tmp
|=
Tmodes
.
at
(
ctr
);
saveascii
(
tmp
,
opts
.
outputfname
.
value
()
+
"_Tmodes"
);
}
}
void
set_TSmode
();
...
...
This diff is collapsed.
Click to expand it.
melodic.cc
+
3
−
3
View file @
fef0d7d3
...
...
@@ -331,9 +331,9 @@ Matrix mmall(Log& logger, MelodicOptions& opts,MelodicData& melodat, MelodicRepo
message
(
" saving probability map: "
);
melodat
.
save4D
(
mixmod
.
get_probmap
(),
string
(
"stats/probmap_"
)
+
num2str
(
ctr
));
%%
message
(
" saving mixture model fit:"
);
%%
melodat
.
saveascii
(
mixmod
.
get_params
(),
%%
string
(
"stats/MMstats_"
)
+
num2str
(
ctr
));
message
(
" saving mixture model fit:"
);
melodat
.
saveascii
(
mixmod
.
get_params
(),
string
(
"stats/MMstats_"
)
+
num2str
(
ctr
));
}
//re-scale spatial maps to mean 0 for nht
...
...
This diff is collapsed.
Click to expand it.
melreport.cc
+
2
−
0
View file @
fef0d7d3
...
...
@@ -770,6 +770,7 @@ namespace Melodic{
}
void
MelodicReport
::
Smode_rep
(){
if
(
melodat
.
get_Smodes
().
size
()
>
0
){
report
<<
"<p><hr><b>TICA Subject/Session modes </b> <br>"
<<
endl
;
miscplot
newplot
;
report
<<
"Boxplots show the relative response amplitudes across the "
...
...
@@ -789,5 +790,6 @@ namespace Melodic{
newplot
.
boxplot
(
allmodes
,
report
.
appendDir
(
string
(
"bp_Smodes.png"
)),
string
(
"Subject/Session modes"
));
report
<<
"<img BORDER=0 SRC=
\"
bp_Smodes.png
\"
><p>"
<<
endl
;
}
}
}
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