Hi All, I have been trying to extract a value from XML. I have been at it for several days off and on and I can't seem to get my head around the problem. I basically understand the examples in R help but I cannot replicate success with the below
I tried to use xmlValue(doc, "//[[value]]") but no success. All I need is the 0.46 value. Any suggestions to help me along are greatly appreciated. Glenn <?xml version="1.0" encoding="utf-8"?> <observations realtime_start="2015-09-21" realtime_end="2015-09-21" observation_start="2015-09-01" observation_end="2015-09-01" units="lin" output_type="1" file_type="xml" order_by="observation_date" sort_order="asc" count="1" offset="0" limit="100000"> <observation realtime_start="2015-09-21" realtime_end="2015-09-21" date="2015-09-01" value="0.46"/> </observations> ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.