Skip to content

Commit

Permalink
Update tutorial docs
Browse files Browse the repository at this point in the history
  • Loading branch information
tuoyl committed Jul 3, 2023
1 parent 38b6b3b commit f21d48a
Show file tree
Hide file tree
Showing 17 changed files with 931 additions and 101 deletions.
47 changes: 45 additions & 2 deletions docs/APIdocs/data.html
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ <h1>Data Classes<a class="headerlink" href="#data-classes" title="Permalink to t

<dl class="py method">
<dt class="sig sig-object py" id="tatpulsar.data.profile.Profile.norm">
<span class="sig-name descname"><span class="pre">norm</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">bkg_range</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/tuoyl/tat-pulsar/blob/master/tatpulsar/data/profile.py"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#tatpulsar.data.profile.Profile.norm" title="Permalink to this definition"></a></dt>
<span class="sig-name descname"><span class="pre">norm</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">method</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">bkg_range</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">return_profile</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/tuoyl/tat-pulsar/blob/master/tatpulsar/data/profile.py"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#tatpulsar.data.profile.Profile.norm" title="Permalink to this definition"></a></dt>
<dd><p>normalize the profile, and return a normalized Profile object</p>
<p>bkg_range is the background phase range selected to calculated the mean level
of background, used in method=0.</p>
Expand All @@ -191,6 +191,10 @@ <h1>Data Classes<a class="headerlink" href="#data-classes" title="Permalink to t
<blockquote>
<div><p>The background phase range for background estimation</p>
</div></blockquote>
<p><strong>return_profile: bool, optional</strong></p>
<blockquote>
<div><p>whether to return the profile, if False modify the attributes</p>
</div></blockquote>
</dd>
</dl>
</dd></dl>
Expand Down Expand Up @@ -219,6 +223,37 @@ <h1>Data Classes<a class="headerlink" href="#data-classes" title="Permalink to t
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="tatpulsar.data.profile.Profile.rebin">
<span class="sig-name descname"><span class="pre">rebin</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">nbins</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">factor</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">return_profile</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/tuoyl/tat-pulsar/blob/master/tatpulsar/data/profile.py"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#tatpulsar.data.profile.Profile.rebin" title="Permalink to this definition"></a></dt>
<dd><p>Rebin the profile into the given bin size or use the factor to
split the intervals.</p>
<dl class="field-list">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>nbins: int</strong></p>
<blockquote>
<div><p>the number of the bins of new profile, if ‘nbins’ is used,
then the ‘factor’ parameter would not work</p>
</div></blockquote>
<p><strong>factor: int</strong></p>
<blockquote>
<div><p>rebin profile to a new shape, new shape must be a factor of the
original shape</p>
</div></blockquote>
<p><strong>return_profile: bool, optional</strong></p>
<blockquote>
<div><p>whether to return the profile, if False modify the attributes</p>
</div></blockquote>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>profile: <cite>Profile</cite> object</p>
<blockquote>
<div><p>return a new profile in one cycle</p>
</div></blockquote>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="tatpulsar.data.profile.Profile.resample">
<span class="sig-name descname"><span class="pre">resample</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">sample_num</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">kind</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">'poisson'</span></span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/tuoyl/tat-pulsar/blob/master/tatpulsar/data/profile.py"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#tatpulsar.data.profile.Profile.resample" title="Permalink to this definition"></a></dt>
Expand Down Expand Up @@ -251,6 +286,14 @@ <h1>Data Classes<a class="headerlink" href="#data-classes" title="Permalink to t
<dd><p>Return the significance in unit of sigma of given profile.</p>
</dd></dl>

<dl class="py property">
<dt class="sig sig-object py" id="tatpulsar.data.profile.Profile.size">
<em class="property"><span class="pre">property</span> </em><span class="sig-name descname"><span class="pre">size</span></span><a class="reference external" href="https://github.com/tuoyl/tat-pulsar/blob/master/tatpulsar/data/profile.py"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#tatpulsar.data.profile.Profile.size" title="Permalink to this definition"></a></dt>
<dd><p>return the real bin size of the profile.
If the profile is presented in 2 cycles, the size is still the
size of the bin size of the profile in 1 cycle.</p>
</dd></dl>

</dd></dl>

<dl class="py function">
Expand Down Expand Up @@ -294,7 +337,7 @@ <h1>Data Classes<a class="headerlink" href="#data-classes" title="Permalink to t

<div role="contentinfo">
<p>&#169; Copyright 2022, Youli.
<span class="lastupdated">Last updated on 2023 Jun 23 at 10:52:32 UTC.
<span class="lastupdated">Last updated on 2023 Jul 04 at 01:05:39 UTC.
</span></p>
</div>

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
249 changes: 226 additions & 23 deletions docs/_sources/notebooks/PulsarTimingAnalysis.ipynb.txt

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/autodocs.html
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ <h1>TAT-pulsar package API<a class="headerlink" href="#tat-pulsar-package-api" t

<div role="contentinfo">
<p>&#169; Copyright 2022, Youli.
<span class="lastupdated">Last updated on 2023 Jun 23 at 10:52:32 UTC.
<span class="lastupdated">Last updated on 2023 Jul 04 at 01:05:39 UTC.
</span></p>
</div>

Expand Down
8 changes: 6 additions & 2 deletions docs/genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -261,10 +261,12 @@ <h2 id="R">R</h2>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="APIdocs/pulse.html#tatpulsar.pulse.residuals.read_toa">read_toa() (in module tatpulsar.pulse.residuals)</a>
</li>
<li><a href="APIdocs/data.html#tatpulsar.data.profile.Profile.resample">resample() (tatpulsar.data.profile.Profile method)</a>
<li><a href="APIdocs/data.html#tatpulsar.data.profile.Profile.rebin">rebin() (tatpulsar.data.profile.Profile method)</a>
</li>
</ul></td>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="APIdocs/data.html#tatpulsar.data.profile.Profile.resample">resample() (tatpulsar.data.profile.Profile method)</a>
</li>
<li><a href="APIdocs/pulse.html#tatpulsar.pulse.Crab.retrive_eph.retrieve_ephemeris">retrieve_ephemeris() (in module tatpulsar.pulse.Crab.retrive_eph)</a>
</li>
<li><a href="APIdocs/utilities.html#tatpulsar.utils.functions.rms">rms() (in module tatpulsar.utils.functions)</a>
Expand All @@ -280,6 +282,8 @@ <h2 id="S">S</h2>
</ul></td>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="APIdocs/data.html#tatpulsar.data.profile.Profile.significance">significance (tatpulsar.data.profile.Profile property)</a>
</li>
<li><a href="APIdocs/data.html#tatpulsar.data.profile.Profile.size">size (tatpulsar.data.profile.Profile property)</a>
</li>
</ul></td>
</tr></table>
Expand Down Expand Up @@ -358,7 +362,7 @@ <h2 id="T">T</h2>

<div role="contentinfo">
<p>&#169; Copyright 2022, Youli.
<span class="lastupdated">Last updated on 2023 Jun 23 at 10:52:32 UTC.
<span class="lastupdated">Last updated on 2023 Jul 04 at 01:05:39 UTC.
</span></p>
</div>

Expand Down
2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ <h2>Contents<a class="headerlink" href="#contents" title="Permalink to this head

<div role="contentinfo">
<p>&#169; Copyright 2022, Youli.
<span class="lastupdated">Last updated on 2023 Jun 23 at 10:52:32 UTC.
<span class="lastupdated">Last updated on 2023 Jul 04 at 01:05:39 UTC.
</span></p>
</div>

Expand Down
Loading

0 comments on commit f21d48a

Please sign in to comment.