Error saying "Error in map_df(1, function(i) { : could not find function "map_df"" in R

0 votes

I have the following code wrt web scraping using R

url_base <- "https://cran.r-project.org/web/packages/available_packages_by_name.html"
map_df(1:100, function(i){
                page <- read_html(sprintf(url_base,i))
                data.frame(IssueID = html_text(html_nodes(page,"h1")),
                       heading = html_text(html_nodes(page,"td")),
                       description = html_text(html_nodes(page,"td")))
}) -> packages

But I end up with the following error, idk why?

Error in map_df(1, function(i) { : could not find function "map_df"
Nov 20, 2018 in Data Analytics by Ali
• 10,380 points
150 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

Make sure you’ve installed the package purr and in case you’ve already installed it and still facing the same error then load that into the library using the following command

library(purr)
answered Nov 20, 2018 by Maverick
• 10,020 points

Related Questions In Data Analytics

0 votes
1 answer

Error: could not find function - R Programming

This error usually occurs when a package ...READ MORE

answered Oct 29, 2018 in Data Analytics by Maverick
• 10,020 points
159 views
0 votes
1 answer
0 votes
1 answer

Error saying "R Error: package ‘lme4’ required by ‘pbkrtest’ could not be found"

Windows 7, revo R 3.2.3 construct a directory ...READ MORE

answered Nov 9, 2018 in Data Analytics by Maverick
• 10,020 points
14 views
0 votes
1 answer

Error saying "could not find function "read_html"" when trying to use read_html function

Hey @Ali, Execute the following two commands: install.packages(“ ...READ MORE

answered Nov 20, 2018 in Data Analytics by Maverick
• 10,020 points
123 views
0 votes
1 answer

Error saying "could not find function "shinyUI"" in shiny R

Its a small spelling mistake that you've ...READ MORE

answered Nov 28, 2018 in Data Analytics by Maverick
• 10,020 points
273 views
0 votes
1 answer

Error saying "could not find function dashboardPage" in shiny R

Include this line in the code: Library(shinydashboard) READ MORE

answered Nov 28, 2018 in Data Analytics by Maverick
• 10,020 points
144 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.