Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
juobs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Javier Ugarrio
juobs
Commits
7a934361
Commit
7a934361
authored
Oct 06, 2022
by
Alejandro Saez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
md_val for TSM corrs
parent
3db1c2e2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
0 deletions
+22
-0
src/juobs_tools.jl
src/juobs_tools.jl
+22
-0
No files found.
src/juobs_tools.jl
View file @
7a934361
...
@@ -470,6 +470,28 @@ function md_val(a::uwreal, obs::Corr, derm::Vector{Corr}; new_version::Bool=fals
...
@@ -470,6 +470,28 @@ function md_val(a::uwreal, obs::Corr, derm::Vector{Corr}; new_version::Bool=fals
ow_data = ow_mean .+ ws.fluc[n_ow]
ow_data = ow_mean .+ ws.fluc[n_ow]
=#
=#
der
=
length
(
a
.
der
)
>=
maximum
(
n_ow
)
?
a
.
der
[
n_ow
]
*
w_mean
:
0.0
der
=
length
(
a
.
der
)
>=
maximum
(
n_ow
)
?
a
.
der
[
n_ow
]
*
w_mean
:
0.0
elseif
all
(
count
.
(
prop
)
.==
3
)
corr_der
=
getfield
.
(
corr
,
:
der
)
n
=
findall
.
(
t
->
t
==
1
,
prop
)
n
=
vcat
(
n
'
...
)
if
all
(
n
[
:
,
1
]
.==
n
[
1
,
1
])
# find ow and w
n_w
=
n
[
1
,
1
]
n_ow1
=
n
[
:
,
2
]
n_ow2
=
n
[
:
,
3
]
elseif
all
(
n
[
:
,
2
]
.==
n
[
1
,
2
])
n_w
=
n
[
1
,
2
]
n_ow1
=
n
[
:
,
1
]
n_ow2
=
n
[
:
,
3
]
elseif
all
(
n
[
:
,
3
]
.==
n
[
1
,
3
])
n_w
=
n
[
1
,
3
]
n_ow1
=
n
[
:
,
1
]
n_ow2
=
n
[
:
,
2
]
end
w_mean
=
1
/
getindex
.
(
corr_der
,
n_ow1
)[
1
]
if
1
/
getindex
.
(
corr_der
,
n_ow1
)[
1
]
!=
1
/
getindex
.
(
corr_der
,
n_ow2
)[
1
]
error
(
"w_mean with n_ow1 and with n_ow2 different"
)
end
der
=
length
(
a
.
der
)
>=
maximum
(
n_ow1
)
&&
length
(
a
.
der
)
>=
maximum
(
n_ow2
)
?
a
.
der
[
n_ow1
]
*
w_mean
:
0.0
else
else
return
nothing
return
nothing
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment