Question 33
Consider the following code and its output:
keep following symbols in mind:
- >>>: Represents input code
- # : Represents comment in a code
- ... : Represents code continuation
- Without any symbols at the beginning of a line then it is output of just above input line of code.
>>> from sklearn.datasets import load_iris>>> from sklearn.linear_model import LogisticRegression
>>> X, y = load_iris(return_X_y=True)>>> clf = LogisticRegression(random_state=0).fit(X, y)
>>> print(y[70:80])[1 0 1 0 1 1 1 0 0 1]
>>> print(clf.predict(X[70:80, :]))[0 1 1 0 1 1 1 0 1 0]
>>> print(clf.score(X[70:80, :], y[70:80]))What will be the output of the above code? Enter your answer correct to one decimal place.