Explore NavigatableString objects.
- [Instructor] Let's explore some navigable string objects.…The first thing we need to do is import Beautiful Soup.…So we'll say from bs4 import Beautiful Soup.…And then we need to create a Beautiful Soup object.…And we'll call the Beautiful Soup constructor and pass in a…tag, now we used this tag in the last demonstration.…I'm just going to copy and paste it in, run that.…And now we have a soup object.…Moving on to navigable strings, let's create…an object called tag and we'll…set it equal to soup.b and then we'll call the type function…on it and verify that we actually have a tag object.…
Yep, Python is returning that we have a tag object here.…So that's good, to verify the name of the tag,…we can simply say tag.name and we can see…that the name of the tag is b.…If you just want to isolate a string object…from within this tag object, all you'd…have to do is say tag.string and it will return…the string that's inside the tag.…So let's try here with tag.string, it's returning…the string that's inside of the tag named b.…
AuthorLillian Pierson, P.E.
- Getting started with Jupyter Notebooks
- Visualizing data: basic charts, time series, and statistical plots
- Preparing for analysis: treating missing values and data transformation
- Data analysis basics: arithmetic, summary statistics, and correlation analysis
- Outlier analysis: univariate, multivariate, and linear projection methods
- Introduction to machine learning
- Basic machine learning methods: linear and logistic regression, Naïve Bayes
- Reducing dataset dimensionality with PCA
- Clustering and classification: k-means, hierarchical, and k-NN
- Simulating a social network with NetworkX
- Creating Plot.ly charts
- Scraping the web with Beautiful Soup
Skill Level Beginner
1. Data Munging Basics
2. Data Visualization Basics
3. Basic Math and Statistics
4. Dimensionality Reduction
Explanatory factor analysis6m 39s
5. Outlier Analysis
6. Cluster Analysis
7. Network Analysis with NetworkX
8. Basic Algorithmic Learning
9. Web-based Data Visualizations with Plotly
10. Web Scraping with Beautiful Soup
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.