Hi I've just downloaded a XML file refering to the 5.8S region in aedes aegyptii from NCBI - nucleotide. As an example I paste the info I get for the first sample in the text.
From here I wish to extract
1. <INSDSeq_accession-version>CH477247.1</INSDSeq_accession-version>
2. <INSDSeq_update-date>23-MAR-2015</INSDSeq_update-date>
3. <INSDSeq_create-date>28-OCT-2005</INSDSeq_create-date>
4. <INSDReference_journal>Submitted (07-OCT-2005) Broad Institute of MIT and Harvard, 320 Charles Street, Cambridge, MA 02141, USA </INSDReference_journal>
Also, as I said this is a short version of all the info I really downloadead (13 samples) https://www.ncbi.nlm.nih.gov/nuccore/?term=aedes+aegypti+5.8, is there a posibility to extract the info I wanted for all the samples?
I`m familiar with R but, which platform suites better to do this?
<INSDSeq_locus>CH477247</INSDSeq_locus>
<INSDSeq_length>3065330</INSDSeq_length>
<INSDSeq_strandedness>double</INSDSeq_strandedness>
<INSDSeq_moltype>DNA</INSDSeq_moltype>
<INSDSeq_topology>linear</INSDSeq_topology>
<INSDSeq_division>CON</INSDSeq_division>
<INSDSeq_update-date>23-MAR-2015</INSDSeq_update-date>
<INSDSeq_create-date>28-OCT-2005</INSDSeq_create-date>
<INSDSeq_definition>Aedes aegypti strain Liverpool supercont1.62 genomic scaffold, whole genome shotgun sequence</INSDSeq_definition>
<INSDSeq_primary-accession>CH477247</INSDSeq_primary-accession>
<INSDSeq_accession-version>CH477247.1</INSDSeq_accession-version>
<INSDSeq_other-seqids>
<INSDSeqid>gnl|WGS:AAGE|supercont1.62</INSDSeqid>
<INSDSeqid>gb|CH477247.1|</INSDSeqid>
<INSDSeqid>gi|78216626</INSDSeqid>
</INSDSeq_other-seqids>
<INSDSeq_project>PRJNA12434</INSDSeq_project>
<INSDSeq_keywords>
<INSDKeyword>WGS</INSDKeyword>
</INSDSeq_keywords>
<INSDSeq_source>Aedes aegypti (yellow fever mosquito)</INSDSeq_source>
<INSDSeq_organism>Aedes aegypti</INSDSeq_organism>
<INSDSeq_taxonomy>Eukaryota; Metazoa; Ecdysozoa; Arthropoda; Hexapoda; Insecta; Pterygota; Neoptera; Holometabola; Diptera; Nematocera; Culicoidea; Culicidae; Culicinae; Aedini; Aedes; Stegomyia</INSDSeq_taxonomy>
<INSDSeq_references>
<INSDReference>
<INSDReference_reference>1</INSDReference_reference>
<INSDReference_position>1..3065330</INSDReference_position>
<INSDReference_authors>
<INSDAuthor>Nene,V.</INSDAuthor>
<INSDAuthor>Wortman,J.R.</INSDAuthor>
<INSDAuthor>Lawson,D.</INSDAuthor>
<INSDAuthor>Haas,B.</INSDAuthor>
<INSDAuthor>Kodira,C.</INSDAuthor>
<INSDAuthor>Tu,Z.J.</INSDAuthor>
<INSDAuthor>Loftus,B.</INSDAuthor>
<INSDAuthor>Xi,Z.</INSDAuthor>
<INSDAuthor>Megy,K.</INSDAuthor>
<INSDAuthor>Grabherr,M.</INSDAuthor>
<INSDAuthor>Ren,Q.</INSDAuthor>
<INSDAuthor>Zdobnov,E.M.</INSDAuthor>
<INSDAuthor>Lobo,N.F.</INSDAuthor>
<INSDAuthor>Campbell,K.S.</INSDAuthor>
<INSDAuthor>Brown,S.E.</INSDAuthor>
<INSDAuthor>Bonaldo,M.F.</INSDAuthor>
<INSDAuthor>Zhu,J.</INSDAuthor>
<INSDAuthor>Sinkins,S.P.</INSDAuthor>
<INSDAuthor>Hogenkamp,D.G.</INSDAuthor>
<INSDAuthor>Amedeo,P.</INSDAuthor>
<INSDAuthor>Arensburger,P.</INSDAuthor>
<INSDAuthor>Atkinson,P.W.</INSDAuthor>
<INSDAuthor>Bidwell,S.</INSDAuthor>
<INSDAuthor>Biedler,J.</INSDAuthor>
<INSDAuthor>Birney,E.</INSDAuthor>
<INSDAuthor>Bruggner,R.V.</INSDAuthor>
<INSDAuthor>Costas,J.</INSDAuthor>
<INSDAuthor>Coy,M.R.</INSDAuthor>
<INSDAuthor>Crabtree,J.</INSDAuthor>
<INSDAuthor>Crawford,M.</INSDAuthor>
<INSDAuthor>Debruyn,B.</INSDAuthor>
<INSDAuthor>Decaprio,D.</INSDAuthor>
<INSDAuthor>Eiglmeier,K.</INSDAuthor>
<INSDAuthor>Eisenstadt,E.</INSDAuthor>
<INSDAuthor>El-Dorry,H.</INSDAuthor>
<INSDAuthor>Gelbart,W.M.</INSDAuthor>
<INSDAuthor>Gomes,S.L.</INSDAuthor>
<INSDAuthor>Hammond,M.</INSDAuthor>
<INSDAuthor>Hannick,L.I.</INSDAuthor>
<INSDAuthor>Hogan,J.R.</INSDAuthor>
<INSDAuthor>Holmes,M.H.</INSDAuthor>
<INSDAuthor>Jaffe,D.</INSDAuthor>
<INSDAuthor>Johnston,J.S.</INSDAuthor>
<INSDAuthor>Kennedy,R.C.</INSDAuthor>
<INSDAuthor>Koo,H.</INSDAuthor>
<INSDAuthor>Kravitz,S.</INSDAuthor>
<INSDAuthor>Kriventseva,E.V.</INSDAuthor>
<INSDAuthor>Kulp,D.</INSDAuthor>
<INSDAuthor>Labutti,K.</INSDAuthor>
<INSDAuthor>Lee,E.</INSDAuthor>
<INSDAuthor>Li,S.</INSDAuthor>
<INSDAuthor>Lovin,D.D.</INSDAuthor>
<INSDAuthor>Mao,C.</INSDAuthor>
<INSDAuthor>Mauceli,E.</INSDAuthor>
<INSDAuthor>Menck,C.F.</INSDAuthor>
<INSDAuthor>Miller,J.R.</INSDAuthor>
<INSDAuthor>Montgomery,P.</INSDAuthor>
<INSDAuthor>Mori,A.</INSDAuthor>
<INSDAuthor>Nascimento,A.L.</INSDAuthor>
<INSDAuthor>Naveira,H.F.</INSDAuthor>
<INSDAuthor>Nusbaum,C.</INSDAuthor>
<INSDAuthor>O'leary,S.</INSDAuthor>
<INSDAuthor>Orvis,J.</INSDAuthor>
<INSDAuthor>Pertea,M.</INSDAuthor>
<INSDAuthor>Quesneville,H.</INSDAuthor>
<INSDAuthor>Reidenbach,K.R.</INSDAuthor>
<INSDAuthor>Rogers,Y.H.</INSDAuthor>
<INSDAuthor>Roth,C.W.</INSDAuthor>
<INSDAuthor>Schneider,J.R.</INSDAuthor>
<INSDAuthor>Schatz,M.</INSDAuthor>
<INSDAuthor>Shumway,M.</INSDAuthor>
<INSDAuthor>Stanke,M.</INSDAuthor>
<INSDAuthor>Stinson,E.O.</INSDAuthor>
<INSDAuthor>Tubio,J.M.</INSDAuthor>
<INSDAuthor>Vanzee,J.P.</INSDAuthor>
<INSDAuthor>Verjovski-Almeida,S.</INSDAuthor>
<INSDAuthor>Werner,D.</INSDAuthor>
<INSDAuthor>White,O.</INSDAuthor>
<INSDAuthor>Wyder,S.</INSDAuthor>
<INSDAuthor>Zeng,Q.</INSDAuthor>
<INSDAuthor>Zhao,Q.</INSDAuthor>
<INSDAuthor>Zhao,Y.</INSDAuthor>
<INSDAuthor>Hill,C.A.</INSDAuthor>
<INSDAuthor>Raikhel,A.S.</INSDAuthor>
<INSDAuthor>Soares,M.B.</INSDAuthor>
<INSDAuthor>Knudson,D.L.</INSDAuthor>
<INSDAuthor>Lee,N.H.</INSDAuthor>
<INSDAuthor>Galagan,J.</INSDAuthor>
<INSDAuthor>Salzberg,S.L.</INSDAuthor>
<INSDAuthor>Paulsen,I.T.</INSDAuthor>
<INSDAuthor>Dimopoulos,G.</INSDAuthor>
<INSDAuthor>Collins,F.H.</INSDAuthor>
<INSDAuthor>Birren,B.</INSDAuthor>
<INSDAuthor>Fraser-Liggett,C.M.</INSDAuthor>
<INSDAuthor>Severson,D.W.</INSDAuthor>
</INSDReference_authors>
<INSDReference_title>Genome sequence of Aedes aegypti, a major arbovirus vector</INSDReference_title>
<INSDReference_journal>Science 316 (5832), 1718-1723 (2007)</INSDReference_journal>
<INSDReference_xref>
<INSDXref>
<INSDXref_dbname>doi</INSDXref_dbname>
<INSDXref_id>10.1126/science.1138878</INSDXref_id>
</INSDXref>
</INSDReference_xref>
<INSDReference_pubmed>17510324</INSDReference_pubmed>
</INSDReference>
<INSDReference>
<INSDReference_reference>2</INSDReference_reference>
<INSDReference_position>1..3065330</INSDReference_position>
<INSDReference_authors>
<INSDAuthor>Galagan,J.</INSDAuthor>
<INSDAuthor>Devon,K.</INSDAuthor>
<INSDAuthor>Henn,M.R.</INSDAuthor>
<INSDAuthor>Severson,D.W.</INSDAuthor>
<INSDAuthor>Collins,F.</INSDAuthor>
<INSDAuthor>Jaffe,D.</INSDAuthor>
<INSDAuthor>Rounsley,S.</INSDAuthor>
<INSDAuthor>DeCaprio,D.</INSDAuthor>
<INSDAuthor>Kodira,C.</INSDAuthor>
<INSDAuthor>Lander,E.</INSDAuthor>
<INSDAuthor>Crawford,M.</INSDAuthor>
<INSDAuthor>Butler,J.</INSDAuthor>
<INSDAuthor>Alvarez,P.</INSDAuthor>
<INSDAuthor>Gnerre,S.</INSDAuthor>
<INSDAuthor>Grabherr,M.</INSDAuthor>
<INSDAuthor>Kleber,M.</INSDAuthor>
<INSDAuthor>Mauceli,E.</INSDAuthor>
<INSDAuthor>Brockman,W.</INSDAuthor>
<INSDAuthor>Young,S.</INSDAuthor>
<INSDAuthor>LaButti,K.</INSDAuthor>
<INSDAuthor>Pushparaj,V.</INSDAuthor>
<INSDAuthor>Koehrsen,M.</INSDAuthor>
<INSDAuthor>Engels,R.</INSDAuthor>
<INSDAuthor>Montgomery,P.</INSDAuthor>
<INSDAuthor>Pearson,M.</INSDAuthor>
<INSDAuthor>Howarth,C.</INSDAuthor>
<INSDAuthor>Zeng,Q.</INSDAuthor>
<INSDAuthor>Yandava,C.</INSDAuthor>
<INSDAuthor>Oleary,S.</INSDAuthor>
<INSDAuthor>Alvarado,L.</INSDAuthor>
<INSDAuthor>Nusbaum,C.</INSDAuthor>
<INSDAuthor>Birren,B.</INSDAuthor>
</INSDReference_authors>
<INSDReference_consortium>The Broad Institute Genome Sequencing Platform</INSDReference_consortium>
<INSDReference_title>Direct Submission</INSDReference_title>
<INSDReference_journal>Submitted (07-OCT-2005) Broad Institute of MIT and Harvard, 320 Charles Street, Cambridge, MA 02141, USA</INSDReference_journal>
</INSDReference>
<INSDReference>
<INSDReference_reference>3</INSDReference_reference>
<INSDReference_position>1..3065330</INSDReference_position>
<INSDReference_authors>
<INSDAuthor>Loftus,B.J.</INSDAuthor>
<INSDAuthor>Nene,V.M.</INSDAuthor>
<INSDAuthor>Hannick,L.I.</INSDAuthor>
<INSDAuthor>Bidwell,S.</INSDAuthor>
<INSDAuthor>Haas,B.</INSDAuthor>
<INSDAuthor>Amedeo,P.</INSDAuthor>
<INSDAuthor>Orvis,J.</INSDAuthor>
<INSDAuthor>Wortman,J.R.</INSDAuthor>
<INSDAuthor>White,O.R.</INSDAuthor>
<INSDAuthor>Salzberg,S.</INSDAuthor>
<INSDAuthor>Shumway,M.</INSDAuthor>
<INSDAuthor>Koo,H.</INSDAuthor>
<INSDAuthor>Zhao,Y.</INSDAuthor>
<INSDAuthor>Holmes,M.</INSDAuthor>
<INSDAuthor>Miller,J.</INSDAuthor>
<INSDAuthor>Schatz,M.</INSDAuthor>
<INSDAuthor>Pop,M.</INSDAuthor>
<INSDAuthor>Pai,G.</INSDAuthor>
<INSDAuthor>Utterback,T.</INSDAuthor>
<INSDAuthor>Rogers,Y.-H.</INSDAuthor>
<INSDAuthor>Kravitz,S.</INSDAuthor>
<INSDAuthor>Fraser,C.M.</INSDAuthor>
</INSDReference_authors>
<INSDReference_title>Direct Submission</INSDReference_title>
<INSDReference_journal>Submitted (07-OCT-2005) The Institute for Genomic Research, 9712 Medical Center Drive, Rockville, MD 20850, USA</INSDReference_journal>
</INSDReference>
<INSDReference>
<INSDReference_reference>4</INSDReference_reference>
<INSDReference_position>1..3065330</INSDReference_position>
<INSDReference_consortium>VectorBase</INSDReference_consortium>
<INSDReference_title>Direct Submission</INSDReference_title>
<INSDReference_journal>Submitted (05-SEP-2012) VectorBase / Ensembl, European Bioinformatics Institute, Wellcome Trust Genome Campus, Hinxton, Cambridge CB10 1SD, UK</INSDReference_journal>
<INSDReference_remark>Annotation update by submitter</INSDReference_remark>
</INSDReference>
</INSDSeq_references>
<INSDSeq_comment>The sequence for this assembly was produced jointly by The Broad Institute of Harvard/MIT and The Institute for Genomic Research. The assembly represents 7.6X sequence coverage of the genome and the total length of the contigs is 1.31 Gb. Additional information about the Aedes aegypti sequencing project and assembly can be found at http://www.broad.mit.edu/annotation/disease_vector/aedes_aegypti/ and http://www.tigr.org/msc/aedes/aedes.shtml. Long-term curation of the sequence and subsequent annotation updates will be the responsibility of VectorBase at http://www.vectorbase.org.~Annotation was updated by VectorBase in Sept 2012.</INSDSeq_comment>
<INSDSeq_feature-table>
<INSDFeature>
<INSDFeature_key>source</INSDFeature_key>
<INSDFeature_location>1..3065330</INSDFeature_location>
<INSDFeature_intervals>
<INSDInterval>
<INSDInterval_from>1</INSDInterval_from>
<INSDInterval_to>3065330</INSDInterval_to>
<INSDInterval_accession>CH477247.1</INSDInterval_accession>
</INSDInterval>
</INSDFeature_intervals>
<INSDFeature_quals>
<INSDQualifier>
<INSDQualifier_name>organism</INSDQualifier_name>
<INSDQualifier_value>Aedes aegypti</INSDQualifier_value>
</INSDQualifier>
<INSDQualifier>
<INSDQualifier_name>mol_type</INSDQualifier_name>
<INSDQualifier_value>genomic DNA</INSDQualifier_value>
</INSDQualifier>
<INSDQualifier>
<INSDQualifier_name>strain</INSDQualifier_name>
<INSDQualifier_value>Liverpool</INSDQualifier_value>
</INSDQualifier>
<INSDQualifier>
<INSDQualifier_name>db_xref</INSDQualifier_name>
<INSDQualifier_value>taxon:7159</INSDQualifier_value>
</INSDQualifier>
<INSDQualifier>
<INSDQualifier_name>chromosome</INSDQualifier_name>
<INSDQualifier_value>2</INSDQualifier_value>
</INSDQualifier>
</INSDFeature_quals>
</INSDFeature>
</INSDSeq_feature-table>
<INSDSeq_contig>join(AAGE02003964.1:1..7226,gap(unk100),AAGE02003965.1:1..6376,gap(unk100),AAGE02003966.1:1..16236,gap(4301),AAGE02003967.1:1..174188,gap(unk100),AAGE02003968.1:1..24199,gap(1396),AAGE02003969.1:1..104064,gap(29770),AAGE02003970.1:1..12303,gap(56956),AAGE02003971.1:1..2368,gap(12542),AAGE02003972.1:1..29888,gap(1379),AAGE02003973.1:1..98175,gap(unk100),AAGE02003974.1:1..13180,gap(unk100),AAGE02003975.1:1..2872,gap(unk100),AAGE02003976.1:1..18626,gap(unk100),AAGE02003977.1:1..52378,gap(151),AAGE02003978.1:1..153108,gap(901),AAGE02003979.1:1..3583,gap(unk100),AAGE02003980.1:1..32852,gap(unk100),AAGE02003981.1:1..68239,gap(unk100),AAGE02003982.1:1..61056,gap(unk100),AAGE02003983.1:1..21852,gap(unk100),AAGE02003984.1:1..49659,gap(unk100),AAGE02003985.1:1..33070,gap(315),AAGE02003986.1:1..411266,gap(unk100),AAGE02003987.1:1..2985,gap(unk100),AAGE02003988.1:1..38365,gap(159),AAGE02003989.1:1..110697,gap(890),AAGE02003990.1:1..22405,gap(2299),AAGE02003991.1:1..7510,gap(187),AAGE02003992.1:1..447937,gap(263),AAGE02003993.1:1..92770,gap(1409),AAGE02003994.1:1..2258,gap(132),AAGE02003995.1:1..5605,gap(unk100),AAGE02003996.1:1..3451,gap(2717),AAGE02003997.1:1..20215,gap(unk100),AAGE02003998.1:1..35683,gap(514),AAGE02003999.1:1..307288,gap(unk100),AAGE02004000.1:1..71359,gap(433),AAGE02004001.1:1..10550,gap(unk100),AAGE02004002.1:1..289125,gap(unk100),AAGE02004003.1:1..45622,gap(unk100),AAGE02004004.1:1..35927)</INSDSeq_contig>
<INSDSeq_xrefs>
<INSDXref>
<INSDXref_dbname>BioProject</INSDXref_dbname>
<INSDXref_id>PRJNA12434</INSDXref_id>
</INSDXref>
<INSDXref>
<INSDXref_dbname>BioSample</INSDXref_dbname>
<INSDXref_id>SAMN02953616</INSDXref_id>
</INSDXref>
</INSDSeq_xrefs>
`
Use an xpath or a CSS selector.
Depending on the language and libraries you use.
I was wondering if anyone knows of a way to get the dates to appear on the x axis of an stl plot.
res<- (stl(ts(data[,variable],frequency=52,start=as.Date(data[1,date]) ),s.window="per",robust=TRUE) )
plot(res)
However this is just producing some unicode labels at the bottom of the chart, I have also tried chaning as.Date to as.character however this didn't work.
dput of some data:
structure(c("2007-01-01", "2007-01-08", "2007-01-15", "2007-01-22",
"2007-01-29", "2007-02-05", "2007-02-12", "2007-02-19", "2007-02-26",
"2007-03-05", "2007-03-12", "2007-03-19", "2007-03-26", "2007-04-02",
"2007-04-09", "2007-04-16", "2007-04-23", "2007-04-30", "2007-05-07",
"2007-05-14", "2007-05-21", "2007-05-28", "2007-06-04", "2007-06-11",
"2007-06-18", "2007-06-25", "2007-07-02", "2007-07-09", "2007-07-16",
"2007-07-23", "2007-07-30", "2007-08-06", "2007-08-13", "2007-08-20",
"2007-08-27", "2007-09-03", "2007-09-10", "2007-09-17", "2007-09-24",
"2007-10-01", "2007-10-08", "2007-10-15", "2007-10-22", "2007-10-29",
"2007-11-05", "2007-11-12", "2007-11-19", "2007-11-26", "2007-12-03",
"2007-12-10", "2007-12-17", "2007-12-24", "2007-12-31", "2008-01-07",
"2008-01-14", "2008-01-21", "2008-01-28", "2008-02-04", "2008-02-11",
"2008-02-18", "2008-02-25", "2008-03-03", "2008-03-10", "2008-03-17",
"2008-03-24", "2008-03-31", "2008-04-07", "2008-04-14", "2008-04-21",
"2008-04-28", "2008-05-05", "2008-05-12", "2008-05-19", "2008-05-26",
"2008-06-02", "2008-06-09", "2008-06-16", "2008-06-23", "2008-06-30",
"2008-07-07", "2008-07-14", "2008-07-21", "2008-07-28", "2008-08-04",
"2008-08-11", "2008-08-18", "2008-08-25", "2008-09-01", "2008-09-08",
"2008-09-15", "2008-09-22", "2008-09-29", "2008-10-06", "2008-10-13",
"2008-10-20", "2008-10-27", "2008-11-03", "2008-11-10", "2008-11-17",
"2008-11-24", "2008-12-01", "2008-12-08", "2008-12-15", "2008-12-22",
"2008-12-29", "2009-01-05", "2009-01-12", "2009-01-19", "2009-01-26",
"2009-02-02", "2009-02-09", "2009-02-16", "2009-02-23", "2009-03-02",
"2009-03-09", "2009-03-16", "2009-03-23", "2009-03-30", "2009-04-06",
"2009-04-13", "2009-04-20", "2009-04-27", "2009-05-04", "2009-05-11",
"2009-05-18", "2009-05-25", "2009-06-01", "2009-06-08", "2009-06-15",
"2009-06-22", "2009-06-29", "2009-07-06", "2009-07-13", "2009-07-20",
"2009-07-27", "2009-08-03", "2009-08-10", "2009-08-17", "2009-08-24",
"2009-08-31", "2009-09-07", "2009-09-14", "2009-09-21", "2009-09-28",
"2009-10-05", "2009-10-12", "2009-10-19", "2009-10-26", "2009-11-02",
"2009-11-09", "2009-11-16", "2009-11-23", "2009-11-30", "2009-12-07",
"2009-12-14", "2009-12-21", "2009-12-28", "2010-01-04", "2010-01-11",
"2010-01-18", "2010-01-25", "2010-02-01", "2010-02-08", "2010-02-15",
"2010-02-22", "2010-03-01", "2010-03-08", "2010-03-15", "2010-03-22",
"2010-03-29", "2010-04-05", "2010-04-12", "2010-04-19", "2010-04-26",
"2010-05-03", "2010-05-10", "2010-05-17", "2010-05-24", "2010-05-31",
"2010-06-07", "2010-06-14", "2010-06-21", "2010-06-28", "2010-07-05",
"2010-07-12", "2010-07-19", "2010-07-26", "2010-08-02", "2010-08-09",
"2010-08-16", "2010-08-23", "2010-08-30", "2010-09-06", "2010-09-13",
"2010-09-20", "2010-09-27", "2010-10-04", "2010-10-11", "2010-10-18",
"2010-10-25", "2010-11-01", "2010-11-08", "2010-11-15", "2010-11-22",
"2010-11-29", "2010-12-06", "2010-12-13", "2010-12-20", "2010-12-27",
"2011-01-03", "2011-01-10", "2011-01-17", "2011-01-24", "2011-01-31",
"2011-02-07", "2011-02-14", "2011-02-21", "2011-02-28", "2011-03-07",
"2011-03-14", "2011-03-21", "2011-03-28", "2011-04-04", "2011-04-11",
"2011-04-18", "2011-04-25", "2011-05-02", "2011-05-09", "2011-05-16",
"2011-05-23", "2011-05-30", "2011-06-06", "2011-06-13", "2011-06-20",
"2011-06-27", "2011-07-04", "2011-07-11", "2011-07-18", "2011-07-25",
"2011-08-01", "2011-08-08", "2011-08-15", "2011-08-22", "2011-08-29",
"2011-09-05", "2011-09-12", "2011-09-19", "2011-09-26", "2011-10-03",
"2011-10-10", "2011-10-17", "2011-10-24", "2011-10-31", "2011-11-07",
"2011-11-14", "2011-11-21", "2011-11-28", "2011-12-05", "2011-12-12",
"2011-12-19", "2011-12-26", "442573", "452832", "452785", "459228",
"479509", "477631", "465619", "462001", "485567", "462381", "456059",
"457401", "474094", "468766", "456945", "539126", "545640", "511801",
"486619", "484430", "481428", "470622", "479677", "486755", "477617",
"483656", "497479", "493436", "480080", "481527", "516029", "532349",
"503939", "472171", "461550", "504532", "489715", "480032", "488376",
"470772", "467395", "488155", "455712", "474456", "471237", "482943",
"459320", "456956", "465056", "461930", "441201", "451255", "464508",
"449199", "455411", "476323", "521761", "513416", "521070", "497596",
"485461", "485593", "461148", "429938", "441207", "459484", "462099",
"469285", "454395", "456729", "469251", "517727", "526719", "477985",
"484538", "469766", "472399", "481162", "479039", "481071", "485068",
"462108", "459079", "452410", "488574", "502166", "504323", "514529",
"524206", "504315", "462935", "461899", "461551", "455491", "456857",
"443314", "454586", "458943", "450555", "454311", "442808", "440126",
"414876", "415787", "413352", "423864", "448319", "415440", "431948",
"433313", "448509", "436400", "454154", "454183", "447735", "452220",
"451433", "472808", "446767", "426595", "463693", "435673", "452704",
"456828", "465069", "448685", "457353", "443859", "463972", "480139",
"493342", "500982", "529602", "527365", "512005", "484585", "455007",
"470006", "477522", "443956", "459038", "488877", "466669", "476242",
"470862", "457298", "466438", "454062", "460216", "466645", "445113",
"457255", "451553", "451504", "447991", "435100", "416140", "481390",
"489041", "496984", "486245", "478191", "455201", "448085", "459097",
"480859", "490248", "462523", "489755", "468391", "460229", "481276",
"472845", "481099", "476435", "487314", "475043", "476847", "461928",
"483488", "479379", "456732", "461538", "480773", "471101", "459898",
"482129", "464356", "459420", "457850", "456764", "438152", "467928",
"464732", "458767", "470256", "449488", "433263", "428548", "435099",
"429163", "424251", "434723", "425841", "399498", "418791", "405051",
"385037", "425144", "418296", "397644", "414283", "431907", "429117",
"424862", "439664", "432791", "443588", "434985", "442418", "445760",
"449290", "451412", "456247", "444372", "441390", "458192", "456435",
"450670", "447609", "439083", "464513", "462784", "439423", "450857",
"442374", "447753", "440207", "435254", "430841", "437233", "426523",
"430127", "431305", "470244", "508878", "511064", "504182", "462076",
"452218", "426535", "436892", "459008", "441449", "438783", "427497",
"432275", "436745", "423068", "429574", "416074"), .Dim = c(261L,
2L))
The problem is with how you have created the time series object.
?ts will give you
start : the time of the first observation. Either a single number or a
vector of two integers, which specify a natural time unit and a
(1-based) number of samples into the time unit.
Since your data starts at 2007-01-01 and is a weekly data, you have to specify c(2007,1), Note that the "1" here denotes that data start from the 1st week of 2007, as the data is weekly. Here the frequency should be set to 52 because, after 52 cycles/weeks a year will change from 2007 to 2008.
This should work
res<- (stl(ts(data[,2],frequency=52,start=c(2007,1 )),s.window="per",robust=TRUE) )