2

I am taking the data science course from Udemy. After running the code to show the iris data set, it does not show. Instead, it downloads a data file.

I am running the following code:

from IPython.display import HTML
HTML('<iframe src=http://archive.ics.uci.edu/ml/machine-learning-databases/iris/iris.data></iframe>')

Is the code correct? Could you please help how to show the iris dataset in the python using iframe?

link to the course: https://www.udemy.com/course/introduction-to-data-science-using-python/learn/lecture/9387344#questions

JohanC
  • 71,591
  • 8
  • 33
  • 66

2 Answers2

0

Try:

pip uninstall prompt-toolkit
pip install prompt-toolkit

The old version: 1.0.14

the new version: 3.0.2

repeated: Problems upgrading Ipython (prompt_toolkit incompatibilities)

Majd Al-okeh
  • 116
  • 4
0

Ali, we can't embed just anything into iframes.

You could just read and display the file as

import pandas as pd

data = pd.read_csv('http://archive.ics.uci.edu/ml/machine-learning-databases/iris/iris.data')

data

This would work just as fine.

Loner
  • 166
  • 1
  • 4
  • 10