Splitting column data [message #1013] |
Mon, 27 July 2020 14:20 ![Go to next message Go to next message](/forum/theme/myThemeWithHFCSS/images/down.png) |
sansun
Messages: 49 Registered: April 2019
|
Member |
|
|
I have a column with references in the following format.
Proc. Natl. Acad. Sci. U.S.A. 105 (26), 9059-9064 (2008)
Is it possible to extract 'journal name', 'year', etc. in separate columns?
|
|
|
Re: Splitting column data [message #1017 is a reply to message #1013] |
Wed, 29 July 2020 10:50 ![Go to previous message Go to previous message](/forum/theme/myThemeWithHFCSS/images/up.png) ![Go to next message Go to next message](/forum/theme/myThemeWithHFCSS/images/down.png) |
thomas
Messages: 693 Registered: June 2014
|
Senior Member |
|
|
if your references would be in a column called 'Lit' you could use something like the attached macro. The problem is that there is no easily recognizable separator between the journal name and the first number. This could be solved with a new function lastIndexOf() or reverseIndexOf(). Please let me know, if your references are similar enough for the macro to work. Then I would add the needed function for the remaining cut to make.
[Updated on: Wed, 29 July 2020 10:51] Report message to a moderator
|
|
|
|
|
Re: Splitting column data [message #1020 is a reply to message #1019] |
Thu, 30 July 2020 07:28 ![Go to previous message Go to previous message](/forum/theme/myThemeWithHFCSS/images/up.png) |
sansun
Messages: 49 Registered: April 2019
|
Member |
|
|
Another observation related to this query.
When I download Chembl data from within Datawarrior (from Database tab), it gives references in the above-mentioned format in a single column.
However, if I directly download data from the Chembl website in the form of .sdf file it gives 'journal name', 'year' etc. in the separate columns.
Probably the later format is better if splitting is going to be a problem.
|
|
|