• R/O
  • SSH

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revision37139e651931737bdbc0cd56fdd463686b017ce7 (tree)
Zeit2014-02-11 05:34:40
AutorLorenzo Isella <lorenzo.isella@gmai...>
CommiterLorenzo Isella

Log Message

I modified the code to run the random forest for the Kaggle loan competition.

Ändern Zusammenfassung

Diff

diff -r 94ccde4d783c -r 37139e651931 Python-codes/loan-minimal.py
--- a/Python-codes/loan-minimal.py Mon Feb 10 21:33:48 2014 +0100
+++ b/Python-codes/loan-minimal.py Mon Feb 10 21:34:40 2014 +0100
@@ -35,7 +35,10 @@
3535 # loss = n.genfromtxt('loss_data.dat',dtype=float)
3636
3737
38-train = pd.read_csv('train_data_fixed.csv')
38+# train = pd.read_csv('train_data_fixed.csv')
39+
40+
41+train = n.loadtxt('train_data_fixed_no_header.dat',dtype="float")
3942
4043 #but I still use numpy for this one as it will return the right 1D array
4144
@@ -48,7 +51,16 @@
4851 # I am now already cleaning and scaling the data in an R code, so I do not need
4952 # to redo this now
5053
51-# train_balance = s.mean(train, axis=0)
54+# train_mean = s.mean(train, axis=0)
55+
56+# train_std= s.std(train, axis=0)
57+
58+# train=train-train_mean
59+# train=train/train_std
60+
61+# n.savetxt("train_mean.dat", train_mean)
62+# n.savetxt("train_std.dat", train_std)
63+
5264
5365 # print "s.shape(train_balance) is, "
5466