Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Carlos-Francisco Méndez-Cruz
/
automatic-extraction-growth-conditions
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
Estefani Gaytan Nunez
2020-02-11 18:16:31 -0600
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
45d4bcd61792364a60d881a382620ac937670989
45d4bcd6
1 parent
24f28a6c
upload
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
CRF/bin/figures/figures-report.py
CRF/bin/figures/figures-report.py
View file @
45d4bcd
...
...
@@ -37,10 +37,12 @@ __author__ = 'egaytan'
def
savescreen
(
output
,
dic
,
path
):
if
output
:
DF
.
from_dict
(
dic
)
.
to_csv
(
path
+
'.csv'
,
sep
=
"
\t
"
,
index
=
True
)
def
plotMax
(
yvalues
,
size
):
def
maxPoint
(
yvalues
):
scorelist
=
list
(
yvalues
)
maxscore
=
max
(
scorelist
)
plt
.
plot
(
scorelist
.
index
(
maxscore
),
maxscore
,
markersize
=
size
)
y
=
max
(
scorelist
)
x
=
scorelist
.
index
(
y
)
return
(
x
,
y
)
#plt.plot(scorelist.index(maxscore), maxscore, markersize=size)
####################################################################################
# MAIN PROGRAM #
...
...
@@ -94,7 +96,8 @@ if __name__ == '__main__':
plt
.
rcParams
.
update
()
plt
.
grid
()
plt
.
plot
(
scoresTable
[
'precision'
],
'co--'
,
label
=
'precision'
,
linewidth
=
1
,
markersize
=
4
)
plotMax
(
scoresTable
[
'precision'
],
8
)
x
,
y
=
maxPoint
(
scoresTable
[
'precision'
])
plt
.
plot
(
x
,
y
,
markersize
=
10
)
plt
.
plot
(
scoresTable
[
'f1-score'
],
'bo--'
,
label
=
'F1'
,
linewidth
=
1
,
markersize
=
4
)
plt
.
plot
(
scoresTable
[
'recall'
],
'mo--'
,
label
=
'recall'
,
linewidth
=
1
,
markersize
=
4
)
plt
.
plot
(
scoresTable
[
'CV'
],
'ro--'
,
label
=
'CV'
,
linewidth
=
1
,
markersize
=
4
)
...
...
Please
register
or
login
to post a comment