Skip to content

Commit

Permalink
Fixed merge issues and update Python examples print calls for Python 3
Browse files Browse the repository at this point in the history
  • Loading branch information
jkbradley committed May 21, 2015
1 parent 0a862f9 commit f16bcec
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions docs/ml-features.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ idf = IDF(inputCol="rawFeatures", outputCol="features")
idfModel = idf.fit(featurizedData)
rescaledData = idfModel.transform(featurizedData)
for features_label in rescaledData.select("features", "label").take(3):
print features_label
print(features_label)
{% endhighlight %}
</div>
</div>
Expand Down Expand Up @@ -282,7 +282,7 @@ sentenceDataFrame = sqlContext.createDataFrame([
tokenizer = Tokenizer(inputCol="sentence", outputCol="words")
wordsDataFrame = tokenizer.transform(sentenceDataFrame)
for words_label in wordsDataFrame.select("words", "label").take(3):
print words_label
print(words_label)
{% endhighlight %}
</div>
</div>
Expand Down Expand Up @@ -368,7 +368,7 @@ binarizer = Binarizer(threshold=0.5, inputCol="feature", outputCol="binarized_fe
binarizedDataFrame = binarizer.transform(continuousDataFrame)
binarizedFeatures = binarizedDataFrame.select("binarized_feature")
for binarized_feature, in binarizedFeatures.collect():
print binarized_feature
print(binarized_feature)
{% endhighlight %}
</div>
</div>
Expand Down Expand Up @@ -781,7 +781,6 @@ scalerModel = scaler.fit(dataFrame)

# Normalize each feature to have unit standard deviation.
scaledData = scalerModel.transform(dataFrame)
>>>>>>> Added Normalizer, StandardScaler to ml-features doc, plus small Java unit tests
{% endhighlight %}
</div>
</div>
Expand Down

0 comments on commit f16bcec

Please sign in to comment.