Skip to content
Marco A. Lopez-Sanchez edited this page Jun 6, 2024 · 6 revisions

Who is this script for?

The script serves three primary goals:

  • Promoting best practices and reproducibility in grain size analysis through robust statistics. It aims to avoid manual steps during data processing and advocates for standard procedures in grain size characterization.
  • Maintaining a curated and up-to-date database piezometric relationships based on recrystallised grain size for various mineral phases.
  • Providing a platform for the implementation and testing of new methods for grain size characterization in recrystallized materials

Specifically, this script is designed for individuals who:

  • Want to visualize grain size distributions.

  • Estimate the magnitude of differential stress in dynamically recrystallized rocks from apparent grain sizes.

  • Aim to approximate the actual (3D) distribution of grain sizes from thin sections using stereological methods. This involves estimating the volume occupied by a particular grain size fraction and a parameter characterizing the shape of the grain size population (assuming a lognormal distribution). The stereological methods assume that grains have equant or near-equant shapes (AR < 2.0), which mostly include all recrystallized grains produced during static and dynamic recrystallization. Additional details are available here.

For igneous studies involving tabular grains far from near-equant objects, we recommend other approaches such as those implemented in the CSDCorrections software (Higgins 2000). See the references list section for details.

Why the grain size distribution plots produced by the GST script and the classic CSD charts do not use the same units on the y-axis?

As you may notice, classic CSDs charts (Marsh, 1988) show in the vertical axis the logarithmic variation in population density or log(frequency) in mm-4, while the stereological methods put in the GrainSizeTools (GST) script returns plots with a linear frequency (per unit volume). This distinction arises from their distinct purposes.

Classic CSD charts (Marsh, 1988) were originally designed for deriving two things in magmatic systems: i) nucleation rates and ii) crystal growth rates. In these systems, small grains are more abundant than large ones and the increase in quantity is typically exponential. The logarithmic scale aids in obtaining a straight line, facilitating the derivation of crystal growth rates and nucleation rates. Further, the intercept of the line at grain size equal to zero allows for estimating the nuclei population density.

In recrystallized rocks, there is no grain size equal to zero and we usually unknown the crystallization time, so the use of CSDs is not optimal. Furthermore, the use of the logarithm in the vertical axis has two main disadvantages for microstructural studies: (i) it obscures the reading of the volume of a particular grain fraction, a common target in microtectonic studies, and (ii) it prevents the easy identification of the features of grain size distribution, which is relevant for applying the two-step method. In summary, the difference in units reflects the specific aims and considerations of each method, with the GST script tailored to microstructural studies in recrystallized rocks.

Why the sum of all frequencies in the histograms is not equal to one?

The sum of all frequencies in the histograms is not equal to one due to the normalization process. After the frequencies are initially normalized to one, indicating that the integral over the range equals one, the procedure divides them by the bin size. Consequently, the sum of all frequency values will not equal one unless the bin size is one. This normalization method was deliberately chosen for several reasons:

  1. Comparing Distributions: It facilitates the comparison of distributions using different bin sizes, allowing for flexibility in the analysis.
  2. Two-Step Method Requirement: This normalization method is necessary for the proper application of the two-step method, ensuring accurate and consistent results across various datasets.

In essence, the non-summing to one outcome is a consequence of a deliberate normalization strategy that enhances the versatility and applicability of the analysis, particularly in scenarios where different bin sizes are employed.

Specifying Script Version in Publications

If you use this script, it is strongly recommended that you specify the version used in your paper, thesis, report, etc. This practice helps ensure transparency and allows others to reproduce your results. Silent bugs in code happen all the time and may (or may not) affect your results. Providing information about the version used will help make your work future-proof, and if there were errors in the calculation, they can be easily corrected from your original data. When indicating the version in your manuscript, consider the following format: "...we used the GrainSizeTools script version x..." and then refer to the general citation:

Lopez-Sanchez, Marco A. (2018). GrainSizeTools: a Python script for grain size analysis and paleopiezometry based on grain size. Journal of Open Source Software, 3(30), 863, https://doi.org/10.21105/joss.00863

Does the script work with Python 2?

No, the script does not work with Python 2 as this Python branch was officially discontinued in 2020, so it is time to move on.

return me to the home page