Skip to content

Commit 972f623

Browse files
zeahmedeerhardt
authored andcommitted
Fixed the syntax of cited example. (#2)
1 parent 76cb2cd commit 972f623

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,10 @@ To build ML.NET from source go to [developers guide](https://github.com/dotnet/m
2626

2727
Simple snippet to train a model for sentiment classification (See the complete sample [here](https://github.com/dotnet/machinelearning/blob/master/test/Microsoft.ML.Tests/Scenarios/Scenario3_SentimentPrediction.cs)):
2828
```C#
29-
var pipeline = new LearningPipeline()
30-
.Add(new TextLoader<SentimentData>(dataPath, separator: ",")
31-
.Add(new TextFeaturizer("Features", "SentimentText")
32-
.Add(new FastTreeBinaryClassifier()
33-
Add(new PredictedLabelColumnOriginalValueConverter(PredictedLabelColumn = "PredictedLabel"});
29+
var pipeline = new LearningPipeline();
30+
pipeline.Add(new TextLoader<SentimentData>(dataPath, separator: ","));
31+
pipeline.Add(new TextFeaturizer("Features", "SentimentText"));
32+
pipeline.Add(new FastTreeBinaryClassifier());
3433
var model = pipeline.Train<SentimentData, SentimentPrediction>();
3534
```
3635

0 commit comments

Comments
 (0)