3 replaced http://stackoverflow.com/ with https://stackoverflow.com/
source | link

Reposted from StackOverflowStackOverflow:

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggsanswer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-queryhttps://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

Reposted from StackOverflow:

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

Reposted from StackOverflow:

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: https://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

2 formatting, links, made obvious it's a repost
source | link

reposted from stackoverflow

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter. Reposted from

StepsStackOverflow:  

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

reposted from stackoverflow

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:  

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

Reposted from StackOverflow:

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query

1
source | link

reposted from stackoverflow

Here are three options

CSV upload to crossref.org

CrossRef allows you to upload the linked csv directly, and then performs a text query here: http://www.crossref.org/stqUpload/

However, only 18 of the 250 queries (~7%) returned a doi.

XML Query

Based on the answer on SO by Brian Diggs, here an attempt that does 95% of the work - toward writing the xml-based query, it still has a few bugs that require some deletion using sed. But the biggest problem that my "session timed out" when the query was submitted.

the xml syntax includes an option to use fuzzy matching.

the doiquery.xml contains the template text in @Brians answer; the citations.csv is linked above. (using R, a sample csv can be found on I have posted the first few lines of the table on google docs, or the csv version (not all records have a doi))

library(XML)
doiquery.xml <- xmlTreeParse('doiquery.xml')

query <- doiquery.xml$doc$children$query_batch[["body"]]

citations <- read.csv("citations.csv")

new.query <- function(citation, query = query){
  xmlValue(query[["author"]]) <- as.character(citation$author)
  xmlValue(query[["year"]]) <- as.character(citation$year)
  xmlValue(query[["article_title"]][["text"]]) <- citation$title
  xmlValue(query[["journal_title"]]) <- citation$journal
  return(query)
}


for (i in 1:nrow(citations)){
  q <- addChildren(q, add.query(citations[i,]))
}
axml <- addChildren(doiquery.xml$doc$children$query_batch, q )

saveXML(axml, file = 'foo.xml')

CSV to XML Converter

Creativyst software provides a web based CSV to XML converter.

Steps:

  1. Enter columnames in ElementID's field,
  2. "document" in DocID field
  3. "query" in RowID field
  4. Copy / paste csv in "Input CSV file".
  5. Click Convert

Also, see this related question: http://stackoverflow.com/questions/9880808/shell-script-to-parse-csv-to-an-xml-query