diff --git a/docs/statlab_corr_spearman_rho.rst b/docs/statlab_corr_spearman_rho.rst index d898d5eb..fc48916c 100644 --- a/docs/statlab_corr_spearman_rho.rst +++ b/docs/statlab_corr_spearman_rho.rst @@ -61,15 +61,15 @@ Let :math:`(Y_{i1}, Y_{i2})` be a pair of random variables corresponding to the Let :math:`(R_{i1}, R_{i2})` be the rank of :math:`Y_{i1}` and the rank of :math:`Y_{i2}`. In the case of ties, one method is to assign the tied group with the average of unique ranks corresponding the tied group. For the :math:`i` th sample, let -:math:`S_{i1}` be the number of observed values less than :math:`Y_{i1}`, -:math:`S_{i2}` be the number of observed values equal to :math:`Y_{i1}`, -and :math:`S_{i3}` be the number of observed values greater to :math:`Y_{i1}`. +:math:`S_{i1,1}` be the number of observed values less than :math:`Y_{i1}`, +:math:`S_{i1,2}` be the number of observed values equal to :math:`Y_{i1}`, +and :math:`S_{i1,3}` be the number of observed values greater to :math:`Y_{i1}`. We can calculate the rank of a single sample as .. math:: :label: eq_rank - R_{i1} = S_{i1} + \frac{S_{i2}+1}{2} = n - S_{i3} - \frac{S_{i2}-1}{2}. + R_{i1} = S_{i1,1} + \frac{S_{i1,2}+1}{2} = n - S_{i1,3} - \frac{S_{i1,2}-1}{2}. For a vector, ``pandas.DataFrame`` has the ``rank`` function with ``method='average'`` option to calculate rank as defined in :eq:`eq_rank`. In ``R``, that can be calculated using the ``rank`` function with ``ties.method='average'`` option. @@ -146,8 +146,9 @@ More Details ************* Assume that :math:`Y_{i1} \sim \mathcal{D}`. -For continuous :math:`Y_{i1}`, if we can assume that :math:`P(S_{i2}=1)=1` for all :math:`i`, -then :eq:`eq_rank` can be simplified as :math:`R_{i1} = S_{i1}+1`. +For continuous :math:`Y_{i1}`, if we can assume +that :math:`P(S_{i1,2}=1)=1` for all :math:`i`, +then :eq:`eq_rank` can be simplified as :math:`R_{i1} = S_{i1,1}+1`. For a given sample size :math:`n`, and :math:`r \in \{1, \ldots, n\}`, the pmf of :math:`R_{i1}` is :math:`P(R_{i1} = r) = \frac{1}{n}`, which does not depend on :math:`r` or :math:`\mathcal{D}` [4]_. diff --git a/docs/std_cdisc.ipynb b/docs/std_cdisc.ipynb index 104ae409..765bea0c 100644 --- a/docs/std_cdisc.ipynb +++ b/docs/std_cdisc.ipynb @@ -26,13 +26,17 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Std/CDISC/Library\n", + "# Std/CDISC/Library Resource\n", "\n", "CDISC stands for Clinical Data Interchange Standards Consortium. \n", "As the name indicated, the organization engages with clinical data community and creates and maintains data standards for clinical developments, \n", "such that the planning, creating, storing, using and exchanging of information and records can be processed at a higher level of consistency [^1].\n", "\n", - "The modules `stdcdisc` include basic functions for processing data already prepared with CDISC standards. " + "The modules `stdcdisc` include basic functions for processing data already prepared with CDISC standards.\n", + "\n", + "Please note that this page is not executed while building. \n", + "Functions and options might be updated as needed.\n", + "Please visit API reference page for the newest information on this module." ] }, { @@ -101,7 +105,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## CDISC Library Resource\n", + "## Access CDISC Library Resource\n", "\n", "Steps: \n", "\n", @@ -126,6 +130,9 @@ "source": [ "### Get CT Packages\n", "\n", + "CDISC Controlled Terminology (CT) is maintained and distributed as part of the National Cancer Institute (NCI) Thesaurus.\n", + "\n", + "\n", "To get a list of newest CT packages available:\n", "\n", "```python\n", @@ -142,11 +149,20 @@ "\n", "```\n", "{'CDASH', 'MRCT', 'COA', 'ADaM', 'Protocol', 'SDTM', 'QRS', 'SEND', 'QS-FT', 'Define-XML', 'Glossary', 'DDF'}\n", - "```\n", + "```" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Some notes about these titles:\n", "\n", - "Please note that this page is not executed while building. \n", - "Functions and options might be updated as needed.\n", - "Please visit API reference page for the newest information on this module." + "- DDF: digital data flow.\n", + "- MRCT: multi-regional clinical trials\n", + "- COA: clinical outcome assessment. This is an archived version. COA is part of QRS supplement supporting FDA COA qualification program [^6].\n", + "- QRS: questionnaires, ratings and scales. This is an archived version. QRS SDTM CT is currently included in SDTM CT. \n", + "- QS-FT: questionnaire and functional test. This is an archived version. This set was merged into COA at 2014 [^r7]." ] }, { @@ -187,6 +203,9 @@ "[^2]: FDA. (year). Data Standards Resource. ([web page](https://www.fda.gov/industry/fda-data-standards-advisory-board/study-data-standards-resources))\n", "[^3]: FDA. (year). Data Standards Catalog. ([web page](https://www.fda.gov/regulatory-information/search-fda-guidance-documents/data-standards-catalog))\n", "[^4]: FDA. (year). Study Data Technical Conformance Guide. ([web page](https://www.fda.gov/regulatory-information/search-fda-guidance-documents/study-data-technical-conformance-guide-technical-specifications-document))\n", + "[^5]: NCI. (yeawr). CDISC Terminology. ([web page](https://datascience.cancer.gov/resources/cancer-vocabulary/cdisc-terminology))\n", + "[^6]: FDA. (2023). Clinical Outcome Assessment (COA) Qualification Program. ([web page](https://www.fda.gov/drugs/drug-development-tool-ddt-qualification-programs/clinical-outcome-assessment-coa-qualification-program))\n", + "[^7]: P21. (2015). CDISC Questionnaire and Functional Test (QS-FT) Terminology has been deprecated. ([web page](https://www.pinnacle21.com/forum/cdisc-questionnaire-and-functional-test-qs-ft-terminology-has-been-deprecated))\n", "\n", "\n", "\n",