[Therion] convert excel to therion
Tarquin Wilton-Jones
tarquin.wilton-jones at ntlworld.com
Wed Dec 21 20:09:58 CET 2022
> i was thinking - maybe someone has some script that does this conversion?
Possibly there is, but there is not really a need to do so for simple
data sets:
1. in Excel, save-as "Text (tab-delimited) (*.txt)", call it foo.th
2. edit it in a text editor
3. add this at the start:
survey foo
centreline
date yyyy.mm.dd
data normal from to length compass clino left right up down
and this at the end:
endcentreline
endsurvey
That's it. Done. Not really enough steps to need a script. If your
spreadsheet has data in this order, you could do it with step 1 only:
survey|foo
centreline
date|yyyy.mm.dd
data|normal|from|to|length|compass|clino|left|right|up|down
1.1|1.2|7.74|331|3.7|1.9|6.4|2|0
endcentreline
endsurvey
If you have a *lot* of files, then yes, maybe you could create a macro
to do it, but the exact information needed would depend on how your
spreadsheet is arranged, so the macro would need to be created
specifically for your spreadsheets, and you could not use someone else's
script. It would depend on the order of your data, and where the date is
written in the spreadsheet, what format the date is written in the
spreadsheet, and where the survey name is written in the spreadsheet.
Your macro would need to rearrange the file to match that format given
above, then save the file as a TSV.
An Excel macro could do all of that, and you could probably record it,
without needing any programming/scripting ability. (Except maybe you
might need to manually put the date in the right format.)
More information about the Therion
mailing list