Displaying 20 results from an estimated 900 matches similar to: "Process XML files"
2011 Jun 29
2
parse XML file
Hi all,
this is my first post in this mailing group. I hope that anyboby could
help me parsing a xml file.
I found this website http://www.omegahat.org/RSXML/gettingStarted.html
but unfortunately my XML file is not as easy as the one in the example.
Example:
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet
2011 May 30
1
Need help reading website info with XML package and XPath
Hi, I'm looking for help extracting some information of the zillow website.
I'd like to do this for the general case where I manually change the address
by modifying the url (see code below). With the url containing the address,
I'd like to be able to extract the same information each time. The specific
information I'd like to be able to extract includes the homedetails url,
price
2011 Jul 05
2
Stuck ...can't get sapply and xmlTreeParse working
Can't seem to get the code below working. It gets stuck on line 24 inside the
function hm; comments show the line in question. The function hm is called
by sapply and is at the bottom of the code. Other stuff above line 24 works
correctly including the first couple of lines of the function hm. Should I
be using a different apply function or am I doing something wrong with
xmlTreeParse ?
2008 Jun 25
0
Memory allocation failed: Copying Node
Following code bugs with "Memory allocation failed: Copying Node" error after
parsing n thousand files. I have included the main code(below) and
functions(after the main code).
I am not sure which lines are causing the copying Node which results in
memory failure. Please advise.
#Beginning of Code
for(i in 1:nrow(newFile)) {
if(i%%3000 == 0) gc()
2005 Jan 12
1
[survey] R for Reporting - the R Output MAnager (ROMA) project
Hi R UseRs,
I am interested in providing Reporting abilities to R and have initiated a
project called R Output MAnager (ROMA).
My starting point was my R2HTML package which provides (rough) HTML
exportations. I began with trying to mimic it for LaTeX but fastly did
realize that it was a bad idea.
Thus, I started again from scratch a new package and did spend a lot of
time reading about this
2005 Mar 11
3
XML to data frame or list
Dear useRs,
I have a simple/RTFM question about XML parsing. Given an XML file,
such as (fragment)
<A>100</A>
<B>23</B>
<C>true</C>
how do I import it in a data frame or list, so that the values (100,
23, true) can be accessed through the names A, B and C?
I installed the XML package and looked over the documentation...
however after 20 minutes and a couple of
2011 Jul 10
1
Help with tryCatch
Having a hard time understanding the help files for tryCatch. Looking for a
little help with the following statement which sits inside a for loop
zest[i] <- tryCatch(sapply(getNodeSet(zdoc, "//zestimate/amount"),
xmlValue), error=function() zest[i] <-"NA")
zest is a numeric vector
If the sapply statement evaluates to an error, I'd like to set the value of
zest[i]
2012 Aug 10
3
Parsing large XML documents in R - how to optimize the speed?
Hello everyone,
I would like to parse very large xml files from MS/MS experiments and
create R objects from their content. (By very large, I mean going up to
5-10Gb, although I am using a 'small' 40M file to test my code.)
My first attempt at parsing the 40M file, using the XML package, took more
than 2200 seconds and left me quite disappointed.
I managed to cut that down to around 40
2012 Apr 26
0
Modifying values into XML with R
Dear R gurus,
I use R all the time at work, so one day a problem managing my personal arise data made me think: "Why not use R, it does everything!".
Anyway, my goal is to use R to manage my personal music library, and more precisely my playcounts. I have two XML files, one from Winamp and the other one from Itunes. Both have pretty much the same songs, but their playcounts are
2013 Mar 13
7
Export R generated tables and figures to MS Word
Dear Rxperts,
I am aware of Sweave that generates reports into a pdf, but do know of any
tools to generate to export to a MS Word document...
Is there a way to use R to generate and export report/publication quality
tables and figures and export them to MS word (for reporting purposes)?
Thanks so much,
Santosh
[[alternative HTML version deleted]]
2012 Oct 03
3
"options" in R
Dear Rxperts,
Was wondering if there is any function in R similar to
options("time.zone"): found in S-Plus that can help in looking at the
default timezone settings..
Thanks much,
Santosh
[
[[alternative HTML version deleted]]
2009 Nov 21
3
"subset" or "condition" as argument to a function
Dear Rxperts!
I was wondering if it is possible to write a function which can take in
argument of a subset or condition.. Of course, I am aware of the alternate
methods like coplot, par.plot, xyplot etc... I am specifically interested in
using conditions/subsets with "plot"..
A simple fragmented example is shown here..
pltit <- function(y,x,dat,dat1,dat2,sbst) {
plot(y~x, data=dat,
2013 Sep 26
2
Read shortcuts of MS Excel files through R
Dear Rxperts,
Through Windows OS, I created shortcuts (paste as shortcut) to excel
spreadsheets ( with "xlsx" as the file extension). I wasn't able to read
the shortcuts through R and using "read" functions of "xlsx" package.
exf <- "a1.xlsx.lnk"
> read.xlsx(exf,1)
Error in .jcall("RJavaTools", "Ljava/lang/Object;",
2013 Mar 26
2
suggestions about import SAS Transport files to R.
Dear Rxperts!
My colleagues used SAS PROC COPY to generate the xpt files that could be
read by the available "xpt" file reading packages in R. However, I am
unable to use the R packages for reading SAS transport files generated
through SAS PROC CPORT. I have tried SASxport, Hmisc, and foreign.
Any ideas/suggestions are more than welcome!
Thanks so much!
Santosh
[[alternative HTML
2011 Apr 19
2
cut & histogram
Dear Rxperts,
Below is a small sample of values (cut short due to space considerations
while posting).. I was wondering if it is possible to construct boundaries
(or intervals) based on the distribution of points. Is it anything similar
to boundary detection of distributions?
x1 <-
2015 Dec 19
2
LDAP create home directories
Hey guys,
I've setup an LDAP server on our network. I'm using OpenLDAP.
It was really easy to use the authconfig-tui to generate the nsswitch.conf
and ldap.conf files that would allow user authentication.
But when users would log in, the system wasn't creating the home
directories.
I found one command that would correct that:
authconfig --enablemkhomedir --update
After that
2012 Nov 27
2
binning by frequency
Dear Rxperts,
is there way to identify intervals from continuous data (having some kind
of a pattern) and then pick the value of most frequency?
a1 <- round(rnorm(50,mean=0,0.1),2)
a2 <- round(rnorm(50,mean=1,0.2),1)
a3 <- round(rnorm(50,mean=5,1),0)
a4 <- round(rnorm(50,mean=14,4),0)
a5 <- round(rnorm(50,mean=30,8),0)
b1 <- rbind(a1,a2,a3,a4,a5)
hist(b1,brea=100) # shows
2013 May 02
3
Lattice xyplot multipanels
Derar Rxperts,
I have a strange situation.. I see curly brackets around "strip.levels" in
multipanel strips while using lattice::xyplot. .How do I get rid of the
curly brackets? For some reason, I am not able to reproduce the problem
using an example below...
Any suggestions are highly welcome!
Thanks,
Santosh
q <-
2011 Apr 27
2
sub-matrix block size
Dear Rxperts
Below is a small vector of values of zeros and non-zeros... was wondering if
there is an efficient way to get the block sizes of submatrices of a big
matrix similar to the one shown below? diagonal elements can be zero too.
Rows with only a diagonal element may be considered as a unit block size.
c(1,0,0,0,0,0,0,0,0,0,0,
1,1,0,0,0,0,0,0,0,0,0,
0,0,1,0,0,0,0,0,0,0,0,
2013 Apr 25
2
RStudio.. text editor
Dear Rxperts/RStudio users,
Is there a way to set tabs (the TAB key) in the text editor of RStudio,
similar to the way customization can be done in Tinn-R?
Thanks and regards,
Santosh
[[alternative HTML version deleted]]