retrieve data sequentially from the R Web page
source link: https://www.codesd.com/item/retrieve-data-sequentially-from-the-r-web-page.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
retrieve data sequentially from the R Web page
I have done an advanced search in a web and get some results. For each result I'm interested in extracting 2 fields, "Referencia:" and "CIF".
#This is the url with the results of the search
url="http://www.boe.es/buscar/boe.php?campo%5B1%5D=DOC&dato%5B1%5D=edicto+auto+declaracion+concurso+CIF
&campo%5B6%5D=FPU&dato%5B6%5D%5B0%5D=25%2F04%2F2013&dato%5B6%5D%5B1%5D=30%2F04%2F2013
&sort_field%5B0%5D=fpu&sort_order%5B0%5D=desc&sort_field%5B1%5D=ref&sort_order%5B1%5D=asc&accion=Buscar"
#This is the url of one of the results.
example=http://www.boe.es/buscar/doc.php?id=BOE-B-2013-15895
The CIF field usually of the form X00000000 or X-00000000 with X=c("A","B")
and 0=0:9
and The Referencia field is BOE-B-2013-15895 in the example and the CIF B-32210196
Could you help me to do it from R?
To grab the content, check out the httr
package. You could use something like
content (GET (url))
Related Articles
How to browse different domain aliases to retrieve their own folders with PHP files from the clean web page?
Selenium To disable the fixed content of the position To delete duplicate data when shooting the entire web page
Using the Selenium and Requests module to get files from the Python3 web page
Allows only PHP files to run with 'permission' from the previous web page
Retrieve entity attributes from the Entity home page (grid view)
How to save content from the Xml Web page as an XML document to the local drive by using C # .Net
How do I send the entire HTML document from the current web page to the server?
Retrieve custom exceptions from the ASMX Web service
Remove margins from the embedded web page
Allow Facebook login from the iframed web page
Get data from the .aspx web page by double-clicking the c # .net button
Add a MySQL entry from the PHP web page
Obtain an absolute path from the external web page images
Retrieves data sequentially using the union operator
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK