Skip to content

Commit

Permalink
fix eXSpy in code examples
Browse files Browse the repository at this point in the history
  • Loading branch information
jlaehne committed Feb 14, 2024
1 parent 11eaaeb commit ea750c3
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 24 deletions.
2 changes: 1 addition & 1 deletion doc/citing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Citing eXSpy
************

**eXSpy** is maintained by the eXSpy community
<https://github.com/hyperspy/eXSpy/contributors>`_.
<https://github.com/hyperspy/exspy/contributors>`_.

If eXSpy has been significant to a project that leads to an academic
publication, please acknowledge that fact by citing it. The DOI in the
Expand Down
6 changes: 3 additions & 3 deletions doc/intro.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Welcome to eXSpy's documentation!
***********************************
Welcome to the documentation of eXSpy!
**************************************
**eXSpy** is a Python package extending the functionality for multi-dimensional
data analysis provided by the `HyperSpy <https://hyperspy.org/>`_ library. It is
aimed at helping with the analysis of X-rays Energy Dispersive Spectroscopy (EDS)
Expand Down Expand Up @@ -99,7 +99,7 @@ Citation in the scientific literature
Given the increasing number of articles that cite HyperSpy and its extension
packages, we do not maintain a list of
articles citing eXSpy or HyperSpy. For an up to date list search for
eXSpy/HyperSpy in a scientific database e.g. `Google Scholar
exspy/HyperSpy in a scientific database e.g. `Google Scholar
<https://scholar.google.co.uk/scholar?q=hyperspy>`_.

.. Warning::
Expand Down
16 changes: 8 additions & 8 deletions doc/user_guide/eds.rst
Original file line number Diff line number Diff line change
Expand Up @@ -149,13 +149,13 @@ will be set by default. These default values can be changed in the

.. code-block:: python
>>> eXSpy.preferences.EDS.eds_detector_elevation = 37
>>> exspy.preferences.EDS.eds_detector_elevation = 37
or through the GUI:

.. code-block:: python
>>> eXSpy.preferences.gui()
>>> exspy.preferences.gui()
.. figure:: images/EDS_preferences_gui.png
:align: center
Expand Down Expand Up @@ -222,7 +222,7 @@ The description of the sample is also stored in the

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles()
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles()
>>> s.add_lines()
>>> s.metadata.Sample.thickness = 100
>>> s.metadata.Sample
Expand All @@ -247,7 +247,7 @@ abbreviations are accepted:

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles()
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles()
>>> s.set_elements(['Fe', 'Pt'])
>>> s.add_elements(['Cu'])
>>> s.metadata.Sample
Expand All @@ -264,7 +264,7 @@ Several lines per element can be defined at once.

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles()
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles()
>>> s.set_elements(['Fe', 'Pt'])
>>> s.set_lines(['Fe_Ka', 'Pt_La'])
>>> s.add_lines(['Fe_La'])
Expand Down Expand Up @@ -476,7 +476,7 @@ Finally, the windows of integration can be visualised using

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles().isig[5.:13.]
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles().isig[5.:13.]
>>> s.add_lines()
>>> s.plot(integration_windows='auto')
Expand Down Expand Up @@ -504,7 +504,7 @@ using :py:meth:`~.signals.EDSSpectrum.plot`:

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles().isig[5.:13.]
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles().isig[5.:13.]
>>> s.add_lines()
>>> bw = s.estimate_background_windows(line_width=[5.0, 2.0])
>>> s.plot(background_windows=bw)
Expand Down Expand Up @@ -700,7 +700,7 @@ out as follows:

.. code-block:: python
>>> s = eXSpy.data.EDS_TEM_FePt_nanoparticles()
>>> s = exspy.data.EDS_TEM_FePt_nanoparticles()
>>> s.add_lines()
>>> kfactors = [1.450226, 5.075602] #For Fe Ka and Pt La
>>> bw = s.estimate_background_windows(line_width=[5.0, 2.0])
Expand Down
24 changes: 12 additions & 12 deletions doc/user_guide/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ To install eXSpy, you have the following options (independent of the operating s
(recommended if you do not use *python* for anything else).
2. :ref:`conda` (recommended if you are also working with other *python* packages).
3. :ref:`pip`.
4. Installing the development version from `GitHub <https://github.com/hyperspy/eXSpy/>`_.
4. Installing the development version from `GitHub <https://github.com/hyperspy/exspy/>`_.
Refer to the appropriate section in the :external+hyperspy:ref:`HyperSpy user guide
<install-dev>` (replacing ``hyperspy`` by ``eXSpy``).
<install-dev>` (replacing ``hyperspy`` by ``exspy``).


.. _conda:
Expand All @@ -43,7 +43,7 @@ environment, if you have one already). To create a new environment:

.. code-block:: bash
(base) conda create -n eXSpy -y
(base) conda create -n exspy -y
2. Installing the package in the new environment
Expand All @@ -53,8 +53,8 @@ Now activate the eXSpy environment and install the package from ``conda-forge``:

.. code-block:: bash
(base) conda activate eXSpy
(eXSpy) conda install -c conda-forge eXSpy -y
(base) conda activate exspy
(exspy) conda install -c conda-forge exspy -y
Required dependencies will be installed automatically.

Expand All @@ -76,9 +76,9 @@ entered into an anaconda prompt (from scratch):

.. code-block:: bash
(base) conda activate eXSpy
(eXSpy) conda install -c conda-forge jupyterlab -y
(eXSpy) jupyter lab
(base) conda activate exspy
(exspy) conda install -c conda-forge jupyterlab -y
(exspy) jupyter lab
.. _pip:
Expand All @@ -91,7 +91,7 @@ and install it using (requires ``pip``):

.. code-block:: bash
pip install eXSpy
pip install exspy
Required dependencies will be installed automatically.

Expand All @@ -103,15 +103,15 @@ Using **conda**:

.. code-block:: bash
conda update eXSpy -c conda-forge
conda update exspy -c conda-forge
Using **pip**:

.. code-block:: bash
pip install eXSpy --upgrade
pip install exspy --upgrade
.. Note::

If you want to be notified about new releases, please *Watch (Releases only)* the `eXSpy repository
on GitHub <https://github.com/hyperspy/eXSpy/>`_ (requires a GitHub account).
on GitHub <https://github.com/hyperspy/exspy/>`_ (requires a GitHub account).

0 comments on commit ea750c3

Please sign in to comment.