pandasgwas.get_studies

get_studies

get_studies(
    study_id: str = None,
    association_id: str = None,
    variant_id: str = None,
    efo_id: str = None,
    pubmed_id: str = None,
    user_requested: bool = None,
    full_pvalue_set: bool = None,
    efo_uri: str = None,
    efo_trait: str = None,
    reported_trait: str = None,
    set_operation: str = "bind",
    interactive: bool = True,
) -> Study

Retrieves Studies via the NHGRI-EBI GWAS Catalog REST API. The REST API is queried multiple times with the criteria passed as arguments. By default all Studies that match the criteria supplied in the arguments are retrieved: this corresponds to the default set_operation set to 'bind', If you rather have only the Studies that match simultaneously all criteria provided, then set set_operation to 'intersection'.

from pandasgwas.get_studies import get_studies_by_study_id
studies = get_studies(study_id='GCST000854')

Parameters:
  • study_id (str, default: None ) –

    Study identifier, accessionId in Study

  • association_id (str, default: None ) –

    Association identifier, associationId in Association

  • variant_id (str, default: None ) –

    Single Nucleotide Polymorphism identifier, rsId in Single Nucleotide Polymorphism

  • efo_id (str, default: None ) –

    EFO Trait identifier, shortForm in EFO Trait

  • pubmed_id (str, default: None ) –

    PubMed identifier

  • user_requested (bool, default: None ) –

    Whether the addition of this study to the Catalog was requested by a user

  • full_pvalue_set (bool, default: None ) –

    Whether full summary statistics are available for this study

  • efo_uri (str, default: None ) –

    EFO URI

  • efo_trait (str, default: None ) –

    Trait description

  • reported_trait (str, default: None ) –

    Trait are reported by the original authors of the study

  • set_operation (str, default: 'bind' ) –

    "bind" or "intersection"

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_all

get_studies_all(interactive: bool = True) -> Study

Gets all Studies

from pandasgwas.get_studies import get_studies_all
studies = get_studies_all()

Parameters:
  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_association_id

get_studies_by_association_id(
    association_id: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by by their Association identifier

from pandasgwas.get_studies import get_studies_by_association_id
studies = get_studies_by_association_id('16510553')

Parameters:
  • association_id (str) –

    Association identifier, associationId in Association

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_efo_id

get_studies_by_efo_id(
    efo_id: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by their EFO Trait identifier

from pandasgwas.get_studies import get_studies_by_efo_id
studies = get_studies_by_efo_id('EFO_0005133')

Parameters:
  • efo_id (str) –

    EFO Trait identifier, shortForm in EFO Trait

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_efo_trait

get_studies_by_efo_trait(
    efo_trait: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies that match trait description

from pandasgwas.get_studies import get_studies_by_efo_trait
studies = get_studies_by_efo_trait('MHPG measurement')

Parameters:
  • efo_trait (str) –

    Trait description

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_efo_uri

get_studies_by_efo_uri(
    efo_uri: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by EFO URI

from pandasgwas.get_studies import get_studies_by_efo_uri
studies = get_studies_by_efo_uri('http://www.ebi.ac.uk/efo/EFO_0005133')

Parameters:
  • efo_uri (str) –

    EFO URI

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_full_pvalue_set

get_studies_by_full_pvalue_set(
    full_pvalue_set: bool, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by full summary statistics criterion

from pandasgwas.get_studies import get_studies_by_full_pvalue_set
studies = get_studies_by_full_pvalue_set('False')

Parameters:
  • full_pvalue_set (bool) –

    Whether full summary statistics are available for this study

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_pubmed_id

get_studies_by_pubmed_id(
    pubmed_id: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by PubMed identifiers

from pandasgwas.get_studies import get_studies_by_pubmed_id
studies = get_studies_by_pubmed_id('21041247')

Parameters:
  • pubmed_id (str) –

    PubMed identifier

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_reported_trait

get_studies_by_reported_trait(
    reported_trait: str, interactive: bool = True
) -> Study

Gets studies that match the reported traits, as reported by the original authors of the study.

from pandasgwas.get_studies import get_studies_by_reported_trait
studies = get_studies_by_reported_trait('Vitamin D levels')

Parameters:
  • reported_trait (str) –

    Trait are reported by the original authors of the study

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_study_id

get_studies_by_study_id(
    study_id: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by Study identifier

from pandasgwas.get_studies import get_studies_by_study_id
studies = get_studies_by_study_id('GCST000854')

Parameters:
  • study_id (str) –

    Study identifier, accessionId in Study

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_user_requested

get_studies_by_user_requested(
    user_requested: bool, interactive: bool = True
) -> Study

Get GWAS Catalog Studies that have been requested by users or not

from pandasgwas.get_studies import get_studies_by_user_requested
studies = get_studies_by_user_requested('True')

Parameters:
  • user_requested (bool) –

    Whether the addition of this study to the Catalog was requested by a user

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object

get_studies_by_variant_id

get_studies_by_variant_id(
    variant_id: str, interactive: bool = True
) -> Study

Get GWAS Catalog Studies by Single Nucleotide Polymorphism identifier

from pandasgwas.get_studies import get_studies_by_variant_id
studies = get_studies_by_variant_id('rs7329174')

Parameters:
  • variant_id (str) –

    Single Nucleotide Polymorphism identifier, rsId in Single Nucleotide Polymorphism

  • interactive (bool, default: True ) –

    Indicates whether to run in interactive mode, when the value is True and the query data is divided into many pages, the function will prompt whether to continue the download.

Returns:
  • Study

    A Study object