.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "_examples/05_crtomo/plot_import_data_to_CR.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr__examples_05_crtomo_plot_import_data_to_CR.py: Single-frequency CRTomo data import ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Import CRTomo-style single-frequency measurement data into a CR container .. GENERATED FROM PYTHON SOURCE LINES 11-12 structure of the input data: .. GENERATED FROM PYTHON SOURCE LINES 12-23 .. code-block:: Python import os input_dir = 'data_crtomo_format' for filename in sorted(os.listdir(input_dir)): print(filename) # the frequencies.dat filename contains the frequencies, corresponding to the # volt* files import subprocess print('content of frequencies.dat') subprocess.call('cat {}/frequencies.dat'.format(input_dir), shell=True) .. rst-class:: sphx-glr-script-out .. code-block:: none frequencies.dat volt_01_0.462963Hz.crt volt_02_1.0Hz.crt volt_03_2.12766Hz.crt volt_04_4.54545Hz.crt volt_05_10.0Hz.crt content of frequencies.dat 0 .. GENERATED FROM PYTHON SOURCE LINES 24-25 import only one frequency into a CR (complex resistivity) container .. GENERATED FROM PYTHON SOURCE LINES 25-29 .. code-block:: Python import reda cr = reda.CR() cr.import_crtomo_data('data_crtomo_format/volt_01_0.462963Hz.crt') .. _sphx_glr_download__examples_05_crtomo_plot_import_data_to_CR.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_import_data_to_CR.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_import_data_to_CR.py ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_