Trying to import non-standard fields, from TXT file

I am trying to export references from the EBSCO version of PsycINFO, and I need to include a non-standard field: TM Tests & Measures.

This problem comes in two parts ..

1. The only way it seems I can export these references (including the TM field) from EBSCO's PsycINFO is in a flat text file. I can't make Zotero import it, despite some posts I've found here saying that this can be done. I *suspect* this is because the TXT file has non-standard fields, but I'm not sure.

I have appended part of one of these TXT files at the bottom of this post, as I can't attach files.

2. There is no field in Zotero for "Tests & Measures" (AFAICT), so from my searches of this forum I believe I would have to use the "Extra" field to contain this information. So would I have to re-name the "Tests & Measures" field as "Extra"? Also, most of the references have multiple entries in the TM field; will copying them all into one field be a problem?

====
Example excerpt from TXT file (one-and-a-bit references):

TI- Meaning in life as a predictor of optimism: How parents mattering matters to Asian and European Americans.
AU- Yu, Elizabeth A.
AU- Chang, Edward C.
AF- Yu, Elizabeth A., aunying@umich.edu, University of Michigan, Department of Psychology, Ann Arbor, MI, US
AF- Chang, Edward C., University of Michigan, Department of Psychology, Ann Arbor, MI, US
AF- ORCID: 0000-0002-0702-6348
AD- Yu, Elizabeth A., University of Michigan, Department of Psychology, 530 Church Street, Ann Arbor, MI, US, 48109, aunying@umich.edu
SO- Personality and Individual Differences
JA- Pers Individ Dif
VI- 138
SD- Feb 1, 2019
YR- 2019
PM- Feb 1, 2019
PG- 366-369
PC- 4
SP- 366
PU- Netherlands : Elsevier Science
PN- 4
SN- 0191-8869, Print
DO- 10.1016/j.paid.2018.10.031
LA- English
KP- Meaning in life
KP- Optimism
KP- Parents mattering
KP- Ethnic differences
KP- Asian Americans
KP- European Americans
SU- Life Satisfaction; Optimism; Parent Child Relations; Racial and Ethnic Differences; Relationship Quality
AB- The present study sought to examine for the relationship between meaning in life (i.e., presence of and searching for) and optimism and the role of parents mattering .. [snip!] .. (PsycINFO Database Record (c) 2018 APA, all rights reserved)
MJ- Life Satisfaction; Optimism; Parent Child Relations; Racial and Ethnic Differences; Relationship Quality
MN- Asians; Meaning; Test Construction; Whites
CL- Personality Traits & Processes (3120)
PO- Human (10)
PO- Male (30)
PO- Female (40)
LO- US
AG- Adulthood (18 yrs & older) (300)
AG- Young Adulthood (18-29 yrs) (320)
TM- Parents Mattering Scale
TM- Meaning in Life Questionnaire DOI: 10.1037/t01074-000
TM- Revised Life Orientation Test DOI: 10.1037/t09267-000
MD- Empirical Study
MD- Quantitative Study
PT- Journal
PT- Peer Reviewed Journal
AT- Journal Article
MT- Electronic
RD- 20181203
CD- 20181231
AN- 2018-56791-061
CP- All rights reserved.. Elsevier Ltd.. 2018
PH- First Posted: Oct 29, 2018; Accepted: Oct 23, 2018; Revised: Jun 17, 2018; First Submitted: Jan 12, 2018
UR- http://ezproxy.uws.edu.au/login?url=http://search.ebscohost.com/login.aspx?direct=true&db=psyh&AN=2018-56791-061&site=ehost-live&scope=site

TI- Effect of negotiable fate on subjective well-being: The mediating role of meaning in life.
AU- Chang, Bao-rui
AU- Bai, Bao-yu
AU- Zhong, Nian
AF- Chang, Bao-rui, Department of Psychology, School of Philosophy, Wuhan University, Wuhan, China
AF- Bai, Bao-yu, psy_bby@163.com, Department of Psychology, School of Philosophy, Wuhan University, Wuhan, China
AF- Zhong, Nian, Department of Psychology, School of Philosophy, Wuhan University, Wuhan, China
AD- Bai, Bao-yu, Department of Psychology, School of Philosophy, Wuhan University, Wuhan, China, 430072, psy_bby@163.com
SO- Chinese Journal of Clinical Psychology
  • To kind of get these into Zotero, you'd have to add
    TY - JOUR at the top of all of them (i.e. do a search&replace for TI - --> TY - JOUR\nTI - (where \n is a new line).

    This would still not importing TM, though and nothing is going to be trivial for that purpose since there are multiple TM tags. I think renaming TM - to N1 - will import every one of these as an individual Note. If you want them in Extra, you'd have to modify the RIS.js import script.
  • Thanks for your help. I'll start by making a TXT file with ~10 references and manually changing it (specifiying type as JOUR and renaming TM to N1), as a test run. If I can get that working, and if having the Tests & Measures info in a Note works OK for me, I will then make a regex tool to automate the changes, and I'll go from there.
  • Emiliano -- thanks!! That script does look almost _suspiciously_ specific to my needs! :-)
  • The cosmic coincidence here is that I had 10 minutes to spare - a rare occasion indeed!
  • You're not a PhD student by any chance are you?? ;-)

    Work-in-progress report .. I have managed to manually alter a (single) reference so that it successfully imports as RIS, with the Tests and Measures importing as Notes.

    (So @adamsmith the renaming to TM to N1 did work.)

    Next is to check that I can do the filtering I need to with the Zotero reference configured this way. If yes, on to the automation; if no, I think I know someone who knows Javascript ..
  • I'll let you know after the qualifier.

    What kind of filtering do you mean?
  • When I download stuff from EBSCO I get normal RIS. I don't have access to PsycINFO but from your snippet this particular mangling of RIS should be detectable and importable -- there are already two other RIS-ish importers in Zotero (MEDLINEnbib and OVID Tagged) so this should be possible.
  • By filtering I mean eliminating articles based on set criteria. (I'm doing a systematic review.) The filter in view here is one which only allows studies which use certain psychometric tests, hence my interest in the Tests & Measures field.

    I'll look into those two importers. But so far, I have had to alter the RIS file to make it work; otherwise it fails.
  • My recommendation would be to change the TM field to KW — this will import the tests as tags, which you can use for searching and filtering.
  • Thanks bwiernik. I tried that and it works nicely; when I export it from Zotero to CSV it shows up in the 'Manual tags' field. (NB this is more for others who may look up this thread in future than for you!). On to regex now.
  • NB when I'm done with this I'll put the tool/s on Github with some notes. Might help others with similar problems.
  • edited January 21, 2019
    Done! That is, with software, not manually - important when you're reformatting more than a thousand references ..

    I recorded a Notepad++ macro. I can't attach files to posts, and I can't post it here, it seems because it's in XML (? mods?). But if anyone wants it, please post here and I'll send it to you.

    NB you have to put "ER- " (no quotes) on the very last line of the TXT file before you run the macro over it.

    I'll also publish it in R when I have some time.

  • You can paste it to http://hastebin.com or GitHub and link here. If it's in XML, then you can wrap it in <code> </code> tags to paste it directly here.
  • Thanks bwiernik. A quick 'n dirty paste is below.

    Also remember (anyone else reading this): add "ER- " on the very last line of the TXT file.


    <Macro name="alter EBSCO generic bibl mgt TXT to RIS format" Ctrl="no" Alt="no" Shift="no" Key="0">
    <Action type="3" message="1700" wParam="0" lParam="0" sParam="" />
    <Action type="3" message="1601" wParam="0" lParam="0" sParam="\nTI- " />
    <Action type="3" message="1625" wParam="0" lParam="1" sParam="" />
    <Action type="3" message="1602" wParam="0" lParam="0" sParam="\nTY- JOUR\nTI- " />
    <Action type="3" message="1702" wParam="0" lParam="770" sParam="" />
    <Action type="3" message="1701" wParam="0" lParam="1609" sParam="" />
    <Action type="3" message="1700" wParam="0" lParam="0" sParam="" />
    <Action type="3" message="1601" wParam="0" lParam="0" sParam="\n(\w\w)- " />
    <Action type="3" message="1625" wParam="0" lParam="2" sParam="" />
    <Action type="3" message="1602" wParam="0" lParam="0" sParam="\n\1 - " />
    <Action type="3" message="1702" wParam="0" lParam="770" sParam="" />
    <Action type="3" message="1701" wParam="0" lParam="1609" sParam="" />
    <Action type="3" message="1700" wParam="0" lParam="0" sParam="" />
    <Action type="3" message="1601" wParam="0" lParam="0" sParam="\nTM - " />
    <Action type="3" message="1625" wParam="0" lParam="1" sParam="" />
    <Action type="3" message="1602" wParam="0" lParam="0" sParam="\nKW - " />
    <Action type="3" message="1702" wParam="0" lParam="770" sParam="" />
    <Action type="3" message="1701" wParam="0" lParam="1609" sParam="" />
    </Macro>
Sign In or Register to comment.