Applicazioni pratiche di machine learning/Riconoscimento della scrittura a mano: differenze tra le versioni

Contenuto cancellato Contenuto aggiunto
mNessun oggetto della modifica
Riga 1:
{{Applicazioni pratiche di machine learning}}
==Caricamento librerie ==
<syntaxhighlight lang="rsplus">
Line 159 ⟶ 160:
Detection Prevalence 0.10225 0.10757 0.09320 0.09558
Balanced Accuracy 0.97694 0.95784 0.92493 0.91197
 
== Parte 4: Previsione ==
Utilizzo infine il modello precedentemente creato per riconoscere i numeri scritti a mano sul testing set:
 
<syntaxhighlight lang="rsplus">
test.data <- predict(pca, newdata = testing)
test.data <- as.data.frame(test.data)
 
rf.pred <- predict(model,test.data)
df <- data.frame(ImageId=1:nrow(testing),Label=rf.pred)
df
write.csv(df, file="digit_recognizer.csv", row.names = FALSE)
</syntaxhighlight>
 
ImageId Label
1 1 2
2 2 0
3 3 9
4 4 9
5 5 3
6 6 7
7 7 0
8 8 3
9 9 0
10 10 3
11 11 5
12 12 7
13 13 4
14 14 0
15 15 4
16 16 3
17 17 3
18 18 1
19 19 9
20 20 0
21 21 9
22 22 1
23 23 1
24 24 5
25 25 7
26 26 4
27 27 2
28 28 7
29 29 9
30 30 7
31 31 7
32 32 5
33 33 4
34 34 2
35 35 6
36 36 2
37 37 5
38 38 5
39 39 1
40 40 6
...
{{avanzamento|75%|29 gennaio 2020}}
[[Categoria:Applicazioni pratiche di machine learning|/Riconoscimento della scrittura a mano]]