When I pars xml (scraping Google RSS) national symbol (Cyrillic) is breaking

0 votes

When I pars xml (scraping Google RSS) national symbol (Cyrillic) is breaking:

>xml <- xmlTreeParse(url, useInternalNodes = T)  
>xml  
<? xml version="1.0" encoding="UTF‑8"?>  
<rss version="2.0">  
<channel>  
<generator>NFE/1.0</generator>  
<title>югра OR ханты OR хмао – Новости Google</title>
Nov 15, 2018 in Data Analytics by Ali
• 10,440 points
37 views

1 answer to this question.

0 votes

try this:

url.tmp <- "http://news.google.ru/news?hl=ru&gl=ru&q="
symbol <- "быть OR жить"
number <- 10
url <- paste(url.tmp, symbol, "&output=rss", "&start=", 1, "&num=", number, sep = "") 
url <- URLencode(url)
answered Nov 15, 2018 by Maverick
• 10,040 points

Related Questions In Data Analytics

0 votes
2 answers

When scoring a logistic regression model , is having the predicted variable in test dataset mandatory ?

Answer to your follow up question: We can ...READ MORE

answered Oct 17, 2018 in Data Analytics by Anmol
• 1,610 points
73 views
0 votes
2 answers

Which language should I learn when starting career as data scientist - R or Python

I'll put down a few parameters on ...READ MORE

answered Oct 26, 2018 in Data Analytics by Kalgi
• 42,430 points
60 views
+5 votes
0 answers
+4 votes
2 answers
0 votes
1 answer

Error saying "vector size cannot be NA" when using R with data mining

You can use the removesparseterm function.  Removes sparse ...READ MORE

answered Nov 15, 2018 in Data Analytics by Maverick
• 10,040 points
537 views
+1 vote
2 answers
0 votes
1 answer

Trying to find frequent itemsets of a data set using arules package

Try replacing ID <- c("A123","A123","A123","A123","B456","B456","B456") item <- c("bread", "butter", "milk", ...READ MORE

answered Nov 15, 2018 in Data Analytics by Maverick
• 10,040 points
45 views
0 votes
1 answer

Error saying "Failed to get an access token." when trying to access my Google Analytics API

Try this: library(RGoogleAnalytics) oauth_token <- Auth( client.id = ...READ MORE

answered Nov 15, 2018 in Data Analytics by Maverick
• 10,040 points
104 views
0 votes
1 answer

Error saying "Error in df$item : object of type 'closure' is not subsettable" when trying to use arules package

Try replacing ID <- c("A123","A123","A123","A123","B456","B456","B456") item <- c("bread", "butter", ...READ MORE

answered Nov 15, 2018 in Data Analytics by Maverick
• 10,040 points
183 views