Zotero Item Type "Document"

We're working on citation style sheets for Value in Health and Spine journals. Looking at the CSL Schema / csl-types.rnc I don't see a type for the Zotero item type "Document". What would it be?

We're almost done with these. They won't be perfect, but how can we make them available to others? Also, they were done in Notepad, so they have CR as well as LF at the end of each line. It doesn't appear to affect their performance on a Windows computer, but I noticed all the other style files don't have CRs in them.
  • Document is a fallback cateogory with no mapping - i.e. any "else" on item types includes document - if you really, really need to use document, you can test for all other item types with match="none", but it's not recommended and may not be longterm stable.

    I believe the repository requires Unix Newlines - if you can't convert it, we will.
  • Another question. Looking at the citation style language I don't see a function that would allow one to test whether a field contains a specific text string. What I need to do is test whether the issue field contains an indication that it was a supplement e.g. "sup". If it does I need to include issue between volume and page. Is there something that can test for a text string in a variable?

  • nope, you can't test for strings/field content.
  • But you can test whether the content is numeric, right? You could do the following:

    <if is-numeric = "issue">
    <text variable="issue" prefix="(" suffix=")"/>
  • So is-numeric will return true on "Supp 1" as well as on "23". Hmmm.

  • What's the precise requirement for supplements as opposed to regular journal articles? It's often possible to work around having to actually recognize supplements to display them correctly.
  • edited January 24, 2012
    "What's the precise requirement for supplements as opposed to regular journal articles?"

    AFAIK, supplements need to have a prefix added to the issue number because their collation is typically independent from the volume/issue (I have had awful trouble locating articles when that indication was missing: in older times, the numbering of supplement would use latin numerals, merely converting them to roman without adding that indication makes the citation incorrect), and that prefix will presumably vary by language ("supp." in English, "suppl." in French, "nachtr." in German...). So if an article in a regular issue is "12(3):123-148", in a supplement it might become "12(supp 1):13-21".
  • edited January 24, 2012
    I added a small extension to the processor a few days ago that could be used for this, using the "Section" field. The processor will parse out a small subset of prefix labels from that field (only) and localize them, so it would be possible to do something like:
    Section: "supp. 1"
    and then have the style use the "section" variable as an optional alternative to "issue".

    (This behavior is not in the CSL specification and is not supported by other processors, but I've introduced it in citeproc-js in order to enable usable support for legislation and other similar primary legal materials.)
  • we will likely get "section" included for journal articles in the future, so then we could implement fbennett's solution.
    Until then, does it not work to just put 'supp. 3' in the issue field? Yes that doesn't localize, but that seems like a small problem.
  • I think on reexamination what rwielage wants is the possibility to have the issue number be available in the data, but included only where required; that is, when it is a supplement.
  • Yes. In the styles I'm working on the issue number is included only if it is a supplement. In that case "supp" is part of the issue number. You can't test whether "sup" is part of the contents of issue and is-numeric can't be used to detect that "Supp 3" isn't numeric.
Sign In or Register to comment.