The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Customize File Import
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

BryanK

Canada
26 Posts

Posted - 11/19/2014 :  4:42:01 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin 9, Windows 7

Hello all,
I was hoping someone would be able to help me build a custom file import for the attached (below) text file? The usual CTRL+3 doesn't have options for Origin to extract titles and units and save the headers somewhere.

For example, this file has about 30+ headers that I would like to keep in Origin as well (even in Notes/comments); also, the tiles/units are set up differently than I can indicate with the subheaders window:
i.e.
Sig1 Title1 (unit1)
Sig2 Title2 (unit2)
Does anyone have any advice for me?
Thanks a lot,
Bryan

quote:
CLOSED
Version 2.0
Language English
Run 1
RunSerial 296
Instrument Q100 V9.9 Build 303
Module Standard - Modulated FC
Operator GD
File \\Ep\ta\DataProcName
InstSerial 0100-0667
Sample PPH100
Size 7.63000 mg
Method
Comment
Xcomment Pan: Aluminum Hermetic
Xcomment Gas1: Helium 25.0 ml/min
Xcomment Gas2: Nitrogen 0.0 ml/min
Text
Exotherm UP
PhaseExo DOWN
Kcell 1.18120
Cpconst MDSC Total: 1.050
Cpconst MDSC Reversing: 1.030
Calib -7.6490
TempCal 1 pts 156.35 156.60
TzeroDt -177.8614 0.0014 0.4739
TzeroDtz -177.8614 0.0320 1.9324
InstCalFile Tzero: \\Lcpodsc\ta\DataInstCalFile Baseline: \\Lcpodsc\ta\DataInstCalFile Sapphire: \\Lcpodsc\ta\DataInstCalDate Tzero 2014-09-02 Time 11:32:26
TempRange -177.85 to 396.77 C at 19.96 C/min Heat Only
AutoZero Delta T Offset -0.103 uV
AutoZero Delta T0 Offset -6.439 uV
Controls Gas 1 Event Off Sampling 0.2
Cell# FC-06403
CoolingUnit LNCS
SelHeatFlow Heat Flow T4 (mW)
AutoAnalysis Off
MacroFile
Nsig 16
Sig1 Time (min)
Sig2 Temperature (C)
Sig3 Heat Capacity (mJ/C)
Sig4 Rev Cp (mJ/C)
Sig5 Nonrev Cp (mJ/C)
Sig6 Heat Flow (mW)
Sig7 Rev Heat Flow (mW)
Sig8 Nonrev Heat Flow (mW)
Sig9 Temperature Amplitude (C)
Sig10 Heat Flow Amplitude (mW)
Sig11 Heat Flow Phase (rad)
Sig12 Modulated Temperature (C)
Sig13 Modulated Heat Flow (mW)
Sig14 Reference Sine Angle (rad)
Sig15 Sample Purge Flow (mL/min)
Sig16 LNCS Pressure (kPa gauge)
Date 2014-11-12
Time 09:27:50
OrgMethod 1: Sampling interval 1.00 s/pt
OrgMethod 2: Data storage Off
OrgMethod 3: Equilibrate at 0.00 C
OrgMethod 4: Modulate 1.00 C every 120 s
OrgMethod 5: Isothermal for 5.00 min
OrgMethod 6: Data storage On
OrgMethod 7: Ramp 2.00 C/min to 50.00 C
OrgMethod 8: Data storage Off
OrgFile C:\TA\DataStartOfData
4.833834 .007503384 0.0000000 15.13408 0.0000000 -9.1103E-3 0.0000000 0.0000000 0.6752311 0.5740046 0.3101115 -0.1383281 -0.5050396 3.159920 23.88431 19.19019
4.850500 .008565530 0.0000000 15.14133 0.0000000 -9.1751E-3 0.0000000 0.0000000 0.6793532 0.5780380 0.3093087 -.09971954 -0.5311055 3.212279 23.98508 20.57895
4.867166 .009622309 0.0000000 15.14839 0.0000000 -9.2209E-3 0.0000000 0.0000000 0.6834695 0.5820610 0.3087267 -.05911592 -0.5579331 3.264639 24.14336 22.22022
4.883834 0.01067185 0.0000000 15.15502 0.0000000 -9.2458E-3 0.0000000 0.0000000 0.6875830 0.5860654 0.3083480 -.01864224 -0.5762444 3.316998 24.18903 23.98773
4.900500 0.01171227 0.0000000 15.16095 0.0000000 -9.2479E-3 0.0000000 0.0000000 0.6916962 0.5900432 0.3081546 0.02300428 -0.5952422 3.369359 24.44500 25.37650
4.917167 0.01274146 0.0000000 15.16596 0.0000000 -9.2261E-3 0.0000000 0.0000000 0.6958121 0.5939868 0.3081214 0.06603174 -0.6098400 3.421719 23.65444 26.00775
4.933834 0.01375721 0.0000000 15.16978 0.0000000 -9.1788E-3 0.0000000 0.0000000 0.6999331 0.5978890 0.3082214 0.1085632 -0.6259679 3.474078 24.86699 25.75525
4.950500 0.01475736 0.0000000 15.17220 0.0000000 -9.1050E-3 0.0000000 0.0000000 0.7040610 0.6017432 0.3084290 0.1511442 -0.6374171 3.526438 23.93901 26.00775
4.967167 0.01573974 0.0000000 15.17310 0.0000000 -9.0035E-3 0.0000000 0.0000000 0.7081974 0.6055434 0.3087140 0.1943619 -0.6485564 3.578798 24.43616 27.01776
4.983834 0.01670206 0.0000000 15.17229 0.0000000 -8.8736E-3 0.0000000 0.0000000 0.7123426 0.6092835 0.3090461 0.2372038 -0.6541528 3.631158 23.83057 23.60898
5.000500 0.01764209 0.0000000 15.16966 0.0000000 -8.7147E-3 0.0000000 0.0000000 0.7164970 0.6129592 0.3093963 0.2799197 -0.6598940 3.683518 23.83070 20.07394
5.017166 0.01855756 0.0000000 15.16515 0.0000000 -8.5258E-3 0.0000000 0.0000000 0.7206597 0.6165669 0.3097346 0.3217865 -0.6638411 3.735878 24.36310 19.06394
5.033834 0.01944626 0.0000000 15.15866 0.0000000 -8.3063E-3 0.0000000 0.0000000 0.7248292 0.6201031 0.3100330 0.3633544 -0.6662016 3.788238 24.47194 19.94769
5.050500 0.02030597 0.0000000 15.15020 0.0000000 -8.0562E-3 0.0000000 0.0000000 0.7290040 0.6235656 0.3102651 0.4047416 -0.6674542 3.840598 24.16435 20.07394
5.067167 0.02113445 0.0000000 15.13977 0.0000000 -7.7754E-3 0.0000000 0.0000000 0.7331809 0.6269520 0.3104052 0.4452714 -0.6679950 3.892957 24.35343 19.19019
5.083834 0.02192952 0.0000000 15.12744 0.0000000 -7.4639E-3 0.0000000 0.0000000 0.7373561 0.6302605 0.3104313 0.4844910 -0.6679337 3.945317 24.38558 19.56894
5.100500 0.02268910 0.0000000 15.11326 0.0000000 -7.1219E-3 0.0000000 0.0000000 0.7415256 0.6334887 0.3103225 0.5223254 -0.6672230 3.997678 24.07701 19.69519
5.117166 0.02341118 0.0000000 15.09735 0.0000000 -6.7497E-3 0.0000000 0.0000000 0.7456842 0.6366344 0.3100625 0.5590937 -0.6646174 4.050037 24.57851 20.32645
5.133833 0.02409385 0.0000000 15.07988 0.0000000 -6.3479E-3 0.0000000 0.0000000 0.7498268 0.6396962 0.3096369 0.5948459 -0.6585772 4.102397 24.21682 21.71521
5.150500 0.02473527 0.0000000 15.06098 0.0000000 -5.9169E-3 0.0000000 0.0000000 0.7539476 0.6426728 0.3090350 0.6288876 -0.6460041 4.154757 23.86044 23.10398
5.167167 0.02533367 0.0000000 15.04085 0.0000000 -5.4577E-3 0.0000000 0.0000000 0.7580401 0.6455647 0.3082492 0.6618690 -0.6277870 4.207116 24.07997 24.36648
5.183833 0.02588740 0.0000000 15.01969 0.0000000 -4.9712E-3 0.0000000 0.0000000 0.7620982 0.6483746 0.3072754 0.6921811 -0.6055717 4.259476 24.05798 25.75525
5.200500 0.02639496 0.0000000 14.99772 0.0000000 -4.4586E-3 0.0000000 0.0000000 0.7661152 0.6511064 0.3061117 0.7219257 -0.5788354 4.311836 24.12756 26.51276
5.217167 0.02685490 0.0000000 14.97519 0.0000000 -3.9214E-3 0.0000000 0.0000000 0.7700848 0.6537652 0.3047615 0.7496124 -0.5529072 4.364196 24.16158 22.09396
5.233833 0.02726590 0.0000000 14.95233 0.0000000 -3.3608E-3 0.0000000 0.0000000 0.7740005 0.6563557 0.3032279 0.7744670 -0.5248334 4.416556 24.36120 20.07394
5.250500 0.02762691 0.0000000 14.92934 0.0000000 -2.7784E-3 0.0000000 0.0000000 0.7778566 0.6588830 0.3015179 0.7979887 -0.4962455 4.468916 24.35990 19.19019
5.267168 0.02793696 0.0000000 14.90650 0.0000000 -2.1759E-3 0.0000000 0.0000000 0.7816474 0.6613524 0.2996415 0.8187009 -0.4654220 4.521276 24.11516 19.82144
5.283832 0.02819529 0.0000000 14.88400 0.0000000 -1.5550E-3 0.0000000 0.0000000 0.7853676 0.6637698 0.2976086 0.8380265 -0.4324924 4.573636 24.51509 19.94769
5.300500 0.02840120 0.0000000 14.86206 0.0000000 -9.1764E-4 0.0000000 0.0000000 0.7890130 0.6661405 0.2954333 0.8545816 -0.4033422 4.625996 24.41675 19.31644
5.317168 0.02855406 0.0000000 14.84090 0.0000000 -2.6544E-4 0.0000000 0.0000000 0.7925788 0.6684700 0.2931297 0.8698712 -0.3687530 4.678356 23.83018 18.68518
5.333832 0.02865346 0.0000000 14.82069 0.0000000 3.99695E-4 0.0000000 0.0000000 0.7960618 0.6707640 0.2907119 0.8813608 -0.3351988 4.730716 23.93915 18.68518
5.350500 0.02869923 0.0000000 14.80161 0.0000000 .001075916 0.0000000 0.0000000 0.7994589 0.6730280 0.2881933 0.8906518 -0.2974005 4.783075 23.76324 18.93768
5.367168 0.02869131 0.0000000 14.78382 0.0000000 .001760859 0.0000000 0.0000000 0.8027679 0.6752680 0.2855914 0.8978710 -0.2608014 4.835434 24.63343 20.07394
5.383832 0.02862969 0.0000000 14.76747 0.0000000 .002452587 0.0000000 0.0000000 0.8059866 0.6774891 0.2829248 0.9027688 -0.2235990 4.887796 23.94469 21.46270
5.400500 0.02851462 0.0000000 14.75266 0.0000000 .003149204 0.0000000 0.0000000 0.8091145 0.6796966 0.2802072 0.9048774 -0.1915774 4.940156 24.44226 22.72522
5.417168 0.02834656 0.0000000 14.73950 0.0000000 .003848881 0.0000000 0.0000000 0.8121508 0.6818944 0.2774540 0.9047672 -0.1499139 4.992515 23.90398 23.98773
5.433832 0.02812600 0.0000000 14.72806 0.0000000 .004549572 0.0000000 0.0000000 0.8150955 0.6840878 0.2746835 0.9026239 -0.1141121 5.044874 23.99260 25.12400
5.450500 0.02785359 0.0000000 14.71844 0.0000000 .005249453 0.0000000 0.0000000 0.8179493 0.6862804 0.2719112 0.8976464 -.07474819 5.097234 24.27869 26.00775
5.467168 0.02753008 0.0000000 14.71062 0.0000000 .005946697 0.0000000 0.0000000 0.8207134 0.6884759 0.2691541 0.8899907 -.03599900 5.149594 24.71001 26.26025
5.483832 0.02715636 0.0000000 14.70466 0.0000000 .006639346 0.0000000 0.0000000 0.8233890 0.6906775 0.2664261 0.8801842 .008012978 5.201954 23.77434 25.62900
5.500500 0.02673346 0.0000000 14.70056 0.0000000 .007325532 0.0000000 0.0000000 0.8259788 0.6928876 0.2637442 0.8679332 0.04602285 5.254314 24.51729 25.75525
5.517168 0.02626252 0.0000000 14.69830 0.0000000 .008003212 0.0000000 0.0000000 0.8284844 0.6951081 0.2611246 0.8527046 0.08554454 5.306674 24.15168 20.07394
5.533832 0.02574483 0.0000000 14.69786 0.0000000 .008670605 0.0000000 0.0000000 0.8309090 0.6973405 0.2585793 0.8350308 0.1263511 5.359034 24.32470 20.45270
5.550500 0.02518184 0.0000000 14.69917 0.0000000 .009325951 0.0000000 0.0000000 0.8332561 0.6995850 0.2561231 0.8149993 0.1646075 5.411392 24.44895 19.19019
5.567168 0.02457510 0.0000000 14.70213 0.0000000 .009967426 0.0000000 0.0000000 0.8355292 0.7018413 0.2537690 0.7929436 0.2085256 5.463754 24.11563 19.69519
5.583832 0.02392619 0.0000000 14.70670 0.0000000 0.01059324 0.0000000 0.0000000 0.8377320 0.7041082 0.2515299 0.7687040 0.2472768 5.516114 24.15565 19.82144
5.600500 0.02323683 0.0000000 14.71273 0.0000000 0.01120175 0.0000000 0.0000000 0.8398686 0.7063843 0.2494170 0.7416788 0.2860956 5.568472 24.17075 19.82144
5.617168 0.02250886 0.0000000 14.72012 0.0000000 0.01179108 0.0000000 0.0000000 0.8419434 0.7086670 0.2474380 0.7121626 0.3263602 5.620834 24.29948 19.69519
5.633832 0.02174431 0.0000000 14.72872 0.0000000 0.01235963 0.0000000 0.0000000 0.8439610 0.7109532 0.2455983 0.6804907 0.3654190 5.673193 24.04852 19.56894
5.650500 0.02094531 0.0000000 14.73838 0.0000000 0.01290588 0.0000000 0.0000000 0.8459266 0.7132398 0.2439043 0.6466785 0.4021260 5.725552 24.11538 19.44269
5.667168 0.02011393 0.0000000 14.74892 0.0000000 0.01342852 0.0000000 0.0000000 0.8478441 0.7155225 0.2423619 0.6120320 0.4356873 5.777912 24.53317 18.81143
5.683832 0.01925225 0.0000000 14.76019 0.0000000 0.01392649 0.0000000 0.0000000 0.8497188 0.7177978 0.2409745 0.5748354 0.4700048 5.830273 24.15406 19.56894
5.700500 0.01836247 0.0000000 14.77205 0.0000000 0.01439872 0.0000000 0.0000000 0.8515549 0.7200616 0.2397396 0.5360768 0.5012604 5.882632 24.75292 21.33646
5.717168 0.01744684 0.0000000 14.78431 0.0000000 0.01484434 0.0000000 0.0000000 0.8533574 0.7223092 0.2386560 0.4953066 0.5325430 5.934992 24.52756 22.97772
5.733832 0.01650771 0.0000000 14.79679 0.0000000 0.01526240 0.0000000 0.0000000 0.8551306 0.7245366 0.2377192 0.4532956 0.5662861 5.987352 24.38521 24.11398
5.750500 0.01554736 0.0000000 14.80931 0.0000000 0.01565188 0.0000000 0.0000000 0.8568791 0.7267386 0.2369258 0.4104634 0.5922731 6.039712 24.06732 25.50275
5.767168 0.01456812 0.0000000 14.82171 0.0000000 0.01601246 0.0000000 0.0000000 0.8586069 0.7289116 0.2362689 0.3656012 0.6201834 6.092072 23.74964 26.00775
5.783832 0.01357232 0.0000000 14.83388 0.0000000 0.01634345 0.0000000 0.0000000 0.8603180 0.7310515 0.2357400 0.3198856 0.6453491 6.144432 24.07116 25.37650
5.800500 0.01256229 0.0000000 14.84562 0.0000000 0.01664428 0.0000000 0.0000000 0.8620162 0.7331543 0.2353314 0.2731825 0.6690419 6.196792 24.75206 20.83145
5.817168 0.01154038 0.0000000 14.85680 0.0000000 0.01691448 0.0000000 0.0000000 0.8637050 0.7352162 0.2350328 0.2250776 0.6946314 6.249152 24.52148 20.07394
5.833832 0.01050890 0.0000000 14.86740 0.0000000 0.01715328 0.0000000 0.0000000 0.8653869 0.7372339 0.2348314 0.1765053 0.7109988 0.6466450 24.20625 19.19019
5.850500 .009470429 0.0000000 14.87707 0.0000000 0.01736082 0.0000000 0.0000000 0.8670656 0.7392040 0.2347189 0.1267040 0.7307175 0.07068637 24.06452 19.94769
5.867168 .008427299 0.0000000 14.88582 0.0000000 0.01753668 0.0000000 0.0000000 0.8687432 0.7411240 0.2346817 0.07722335 0.7458218 0.1230462 24.56519 18.93768
5.883832 .007381855 0.0000000 14.89356 0.0000000 0.01768062 0.0000000 0.0000000 0.8704219 0.7429918 0.2347086 0.02677198 0.7593678 0.1754061 24.31813 19.06394
5.900500 .006336456 0.0000000 14.90021 0.0000000 0.01779246 0.0000000 0.0000000 0.8721035 0.7448058 0.2347868 -.02277793 0.7697119 0.2277660 23.85824 19.44269
5.917168 .005293484 0.0000000 14.90573 0.0000000 0.01787198 0.0000000 0.0000000 0.8737886 0.7465644 0.2349042 -.07250564 0.7755169 0.2801259 24.33952 20.20020
5.933832 .004255426 0.0000000 14.91000 0.0000000 0.01791866 0.0000000 0.0000000 0.8754786 0.7482668 0.2350485 -0.1222930 0.7819404 0.3324857 23.99606 21.96771
5.950500 .003224844 0.0000000 14.91302 0.0000000 0.01793160 0.0000000 0.0000000 0.8771735 0.7499126 0.2352077 -0.1724188 0.7860726 0.3848456 24.26744 23.35648
5.967168 .002204377 0.0000000 14.91470 0.0000000 0.01791027 0.0000000 0.0000000 0.8788728 0.7515014 0.2353688 -0.2213230 0.7885308 0.4372055 24.23142 24.74524
5.983832 .001196559 0.0000000 14.91500 0.0000000 0.01785437 0.0000000 0.0000000 0.8805762 0.7530322 0.2355205 -0.2689758 0.7908866 0.4895654 24.43126 26.13400
6.000500 2.03922E-4 0.0000000 14.91398 0.0000000 0.01776379 0.0000000 0.0000000 0.8822826 0.7545040 0.2356522 -0.3163112 0.7917280 0.5419254 23.95126 25.62900
6.017168 -7.7103E-4 0.0000000 14.91159 0.0000000 0.01763824 0.0000000 0.0000000 0.8839899 0.7559151 0.2357531 -0.3625224 0.7917488 0.5942851 23.73423 25.62900
6.033832 -1.7258E-3 0.0000000 14.90794 0.0000000 0.01747777 0.0000000 0.0000000 0.8856964 0.7572634 0.2358134 -0.4082912 0.7907249 0.6466450 23.98070 19.56894
6.050500 -2.6578E-3 0.0000000 14.90309 0.0000000 0.01728289 0.0000000 0.0000000 0.8873989 0.7585478 0.2358244 -0.4523344 0.7877804 0.6990050 23.78983 19.56894
6.067168 -3.5646E-3 0.0000000 14.89712 0.0000000 0.01705363 0.0000000 0.0000000 0.8890949 0.7597674 0.2357792 -0.4962374 0.7826749 0.7513648 24.40194 19.19019
6.083832 -4.4439E-3 0.0000000 14.89009 0.0000000 0.01679019 0.0000000 0.0000000 0.8907816 0.7609228 0.2356717 -0.5369122 0.7717400 0.8037247 24.40831 19.82144
9.783832 2.855219 15.78332 14.20945 1.573872 -0.5010580 -0.4736484 -.02740953 0.9071034 0.7456687 0.1743330 3.513422 -0.2174905 6.144432 24.40995 20.32645
9.800500 2.886206 15.76946 14.22868 1.540785 -0.5006180 -0.4742893 -.02632862 0.9058441 0.7456850 0.1731959 3.513989 -0.1848498 6.196792 24.11604 20.95770
9.817166 2.917190 15.75593 14.25015 1.505776 -0.5001883 -0.4750050 -.02518317 0.9045261 0.7457615 0.1720729 3.513440 -0.1540444 6.249152 23.93352 21.21020
9.833832 2.948165 15.74224 14.27402 1.468212 -0.4997535 -0.4758008 -.02395275 0.9031522 0.7459000 0.1709799 3.510999 -0.1261983 0.6466452 24.19846 20.95770
9.850500 2.979128 15.72930 14.30011 1.429184 -0.4993428 -0.4766704 -.02267236 0.9017241 0.7461018 0.1699265 3.507144 -.09544715 0.07068671 24.40636 20.83145
9.867166 3.010074 15.71664 14.32851 1.388137 -0.4989411 -0.4776169 -.02132421 0.9002460 0.7463672 0.1689280 3.501531 -.06735605 0.1230466 23.97350 20.70520
9.883832 3.040999 15.70435 14.35918 1.345169 -0.4985508 -0.4786394 -.01991145 0.8987220 0.7466964 0.1679976 3.494680 -.04277090 0.1754065 24.59012 20.45270
9.900500 3.071900 15.69241 14.39210 1.300315 -0.4981718 -0.4797366 -.01843528 0.8971574 0.7470891 0.1671503 3.487092 -.01577498 0.2277663 23.93606 20.32645
9.917168 3.102774 15.68086 14.42716 1.253694 -0.4978050 -0.4809054 -.01689958 0.8955569 0.7475432 0.1663991 3.477828 .006648026 0.2801262 24.29330 20.32645
9.933832 3.133616 15.66964 14.46424 1.205404 -0.4974489 -0.4821412 -.01530770 0.8939269 0.7480566 0.1657555 3.468122 0.03099222 0.3324861 24.56206 20.07394
9.950500 3.164426 15.65878 14.50316 1.155616 -0.4971041 -0.4834387 -.01366536 0.8922734 0.7486260 0.1652316 3.456917 0.05130688 0.3848460 24.08429 19.44269
9.967168 3.195200 15.64845 14.54378 1.104672 -0.4967762 -0.4847926 -.01198362 0.8906030 0.7492478 0.1648367 3.445710 0.06884750 0.4372059 23.90641 19.69519
9.983832 3.225934 15.63866 14.58587 1.052798 -0.4964656 -0.4861957 -.01027002 0.8889228 0.7499179 0.1645792 3.433286 0.08724566 0.4895657 24.00930 19.69519
10.00050 3.256628 15.62944 14.62923 1.000219 -0.4961729 -0.4876410 -8.5320E-3 0.8872398 0.7506308 0.1644652 3.420227 0.1022446 0.5419256 24.50288 18.81143
10.01717 3.287281 15.62086 14.67362 0.9472441 -0.4959004 -0.4891205 -6.7798E-3 0.8855612 0.7513803 0.1644987 3.407574 0.1175240 0.5942856 24.02968 20.07394
10.03383 3.317889 15.61295 14.71879 0.8941647 -0.4956494 -0.4906262 -5.0230E-3 0.8838941 0.7521595 0.1646822 3.393738 0.1275775 0.6466455 24.67635 21.96771
10.05050 3.348452 15.60570 14.76449 0.8412091 -0.4954191 -0.4921497 -3.2694E-3 0.8822453 0.7529630 0.1650160 3.379656 0.1372084 0.6990051 24.22167 23.48273
10.06717 3.378968 15.59915 14.81044 0.7887116 -0.4952112 -0.4936813 -1.5298E-3 0.8806225 0.7537848 0.1654991 3.366750 0.1426364 0.7513651 24.19100 24.61899
10.08383 3.409437 15.59340 14.85640 0.7369982 -0.4950285 -0.4952133 1.84798E-4 0.8790313 0.7546197 0.1661284 3.353340 0.1475273 0.8037250 24.23169 26.13400
10.10050 3.439858 15.58828 14.90211 0.6861688 -0.4948662 -0.4967371 .001870992 0.8774788 0.7554616 0.1668988 3.339999 0.1500978 0.8560849 24.26680 26.26025
10.11717 3.470230 15.58378 14.94736 0.6364107 -0.4947231 -0.4982456 .003522442 0.8759706 0.7563050 0.1678048 3.327483 0.1518337 0.9084449 24.09597 25.62900
10.13383 3.500554 15.58006 14.99191 0.5881511 -0.4946053 -0.4997305 .005125213 0.8745124 0.7571434 0.1688388 3.315340 0.1533062 0.9608047 24.20041 19.44269
10.15050 3.530828 15.57706 15.03552 0.5415370 -0.4945097 -0.5011840 .006674236 0.8731094 0.7579711 0.1699926 3.303436 0.1547539 1.013164 23.89734 20.20020
10.16717 3.561053 15.57490 15.07799 0.4969148 -0.4944414 -0.5025996 .008158228 0.8717658 0.7587815 0.1712564 3.292307 0.1554460 1.065524 23.88882 19.31644
10.18383 3.591228 15.57358 15.11911 0.4544732 -0.4943996 -0.5039704 .009570848 0.8704859 0.7595686 0.1726202 3.282094 0.1557307 1.117884 24.25345 19.82144
10.20050 3.621355 15.57316 15.15872 0.4144430 -0.4943860 -0.5052906 0.01090451 0.8692734 0.7603269 0.1740736 3.273216 0.1553273 1.170244 24.29942 19.94769
10.21717 3.651432 15.57324 15.19665 0.3765970 -0.4943887 -0.5065549 0.01216618 0.8681311 0.7610511 0.1756050 3.264810 0.1536580 1.222604 24.55222 20.70520
10.23383 3.681462 15.57400 15.23277 0.3412258 -0.4944126 -0.5077591 0.01334643 0.8670613 0.7617364 0.1772033 3.258506 0.1482866 1.274964 24.22765 22.72522
10.25050 3.711444 15.57546 15.26697 0.3084875 -0.4944590 -0.5088989 0.01444001 0.8660663 0.7623791 0.1788563 3.253397 0.1388931 1.327324 24.00999 23.73523
10.26717 3.741379 15.57755 15.29916 0.2783967 -0.4945254 -0.5099720 0.01544637 0.8651475 0.7629776 0.1805527 3.248716 0.1228486 1.379684 24.38328 24.99774
10.28383 3.771268 15.58023 15.32926 0.2509711 -0.4946106 -0.5109753 0.01636480 0.8643055 0.7635312 0.1822826 3.246913 0.1009627 1.432044 24.19335 26.51276
10.30050 3.801110 15.58356 15.35721 0.2263442 -0.4947162 -0.5119071 0.01719099 0.8635408 0.7640406 0.1840334 3.245330 0.07707755 1.484403 24.31326 19.06394
10.31717 3.830910 15.58738 15.38301 0.2043822 -0.4948376 -0.5127668 0.01792913 0.8628532 0.7645075 0.1857956 3.246015 0.05206882 1.536763 24.29999 20.07394

jasonzhao

China
262 Posts

Posted - 11/20/2014 :  03:09:13 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello,

Based on the graph depicted, I would like to make sure that the problem is:
1. How to save all the content without data in a separate note file;
2. and how to map the UNIT (Sig 1, 2, 3 ...) across each column on the head of the data.

Best regards,
Jason Zhao
OriginLab Tech Service
Go to Top of Page

BryanK

Canada
26 Posts

Posted - 11/21/2014 :  1:24:02 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for your reply Jason,
1: Doesn't matter, but I would like Origin to keep all of the headers somewhere.
2: Correct - my main question

Cheers,
Bryan

quote:
Originally posted by jasonzhao

Hello,

Based on the graph depicted, I would like to make sure that the problem is:
1. How to save all the content without data in a separate note file;
2. and how to map the UNIT (Sig 1, 2, 3 ...) across each column on the head of the data.

Best regards,
Jason Zhao
OriginLab Tech Service


Go to Top of Page

jasonzhao

China
262 Posts

Posted - 11/25/2014 :  03:24:40 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello,

You can use the script to solve this problem,

First, please import the data in a Data book by Import Wizard, and skip all the head rows.




Then, run the script in script window:


newbook Temp;
impASC fname:="D:\test.txt" options.FileStruct.DataStruct:=2 options.FileStruct.MultipleDelimiters:="Sig" ; // put file path in the " "


a new book is created for save the longname temporarily, with this book active, run the script:


stringarray longname;
string tempname$;

for(int ii=1;ii<17;ii++){
tempname$=col(2)[$(ii)]$;
for(int j=0;j<10;j++)
{
tempname.Remove($(j));  // remove numbers
}
tempname.Remove('	');
longname.add(tempname$);
}

A string array was created, and all the "column name" is saved in it.


Finally, please go back to the Data book, run the script:


for(int ii=1;ii<17;ii++){
col($(ii))[L]$=longname.GetAt($(ii))$;
}

this section map the UNIT (Sig 1, 2, 3 ...) across each column on the head of the data.

you can get the results like this:



Please run each section by highlight the script and click ENTER, separately.


Best regards,
Jason Zhao
OriginLab Tech Service

Edited by - jasonzhao on 11/25/2014 03:35:14 AM
Go to Top of Page

BryanK

Canada
26 Posts

Posted - 11/30/2014 :  06:09:58 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for that reply Jason!
I have tested the scripts and they do the job. I will play with the script and learn how to save this as a template for future imports of this type.

I have a few follow up questions if you could:
- what does the $ sign represent in this code? I use it but don't really know why.
- Do you have the script to make the brackets (mg) etc. transposed into the UNITS column? (This is something I will try on my own too)
- What is [L]?
- Where is the best reference "book" for the script? I've been mostly scripting based on OriginForum user examples.

Thanks a lot,
Go to Top of Page

jasonzhao

China
262 Posts

Posted - 11/30/2014 :  10:36:33 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello,

This is the best reference "book" for the LabTalk Script
http://www.originlab.com/doc/LabTalk/guide

for $ sign, please see this page:
http://www.originlab.com/doc/LabTalk/guide/Substitution-Notation#.24.28_.29_Substitution.24.28_.29_Substitution

and for [L]:
http://www.originlab.com/doc/LabTalk/ref/Column-Label-Row-Characters

Besides, if you want to transpose (mg) into the UNITS column, you can refer to
http://www.originlab.com/doc/LabTalk/ref/String-and-Characters

Best regards,
Jason Zhao
OriginLab Tech Service
Go to Top of Page

cdrozdowski111

USA
247 Posts

Posted - 12/01/2014 :  05:26:36 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Bryan,

I had some unit-extracting code fairly handy and quickly adapted it to your needs.

So, if you want to extract the units, then replace the last script Jason provided with the one below. I added comments to help you understand what is going on.

for (int ii = 1; ii <= longname.GetSize(); ii++) // Loop through each item in stringarray- it represents a column long name and units
{
	string sItem$ = longname.GetAt($(ii))$; // Get current item from stringarray as new string variable
	sItem.Remove(""); // Remove funky character that may show up in new string (it does for me)
	int nPos = sItem.ReverseFind("("); // Find the position of "(" character going backwards through new string variable

	if (nPos > 0) // See if "(" was found in new string indicating units within () characters
	{
		// It was found, extract units
		string sUnits$ = sItem.Mid(nPos + 1)$; // Extract characters after the "(" from current item string into another new string
		sUnits.TrimRight(")"); // Remove ")" character from end of new string
		col($(ii))[U]$ = sUnits$; // Assign new string to Units label row in column

		string sLongName$ = sItem.Left(nPos)$;  // Now, extract characters up to (and including) the "(" from current stringarray item string into yet another new string
		sLongName.TrimRight(" ("); // Remove "(" character and any spaces from end of new string
		col($(ii))[L]$ = sLongName$; // Assign new string to Long Name label row in column
	}
	else // Safety net just in case "(" wasn't found indicating no units in () characters. Shouldn't happen with your data.
	{
		col($(ii))[L]$ = sItem$; // Simply assign current stringarray item to Long Name label row in column
	}
}
Go to Top of Page

BryanK

Canada
26 Posts

Posted - 12/07/2014 :  2:34:46 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks to both of you. The code works nicely and I will slowly work to automate it - ideally for batch import of these files.

I've got some homework to do!

Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000