Python functions for opentargets.org API

Overview

What is opy_Targets?

Opentargets.org uses GraphQL API to explore it's content via coding. This ensemble of functions aim is to make it easy to use the API via our beloved coding language - python <3

Python dependencies

(requires Python 3)

  • pandas
  • requests
  • json

Usage

Example:

Lets say you want to get SNPS of gene you think is related to a disease

import opy_targets as opy

ENDOMETRIOSIS_EFO_ID = 'EFO_0001065'
SNP_ESNG_ID = ENSG00000196208

opy.get_snp_data(SNP_ESNG_ID,ENDOMETRIOSIS_ID).head(4)

output:

variantRsId variantId studyId studySampleSize publicationFirstAuthor label chr location disease_ID gene_related
0 rs11674184 2_11581409_T_G GCST004549 208903 Sapkota Y intron_variant 2 11581409 EFO_0001065 ENSG00000196208
1 rs11674184 2_11581409_T_G GCST004549_2 208903 Sapkota Y intron_variant 2 11581409 EFO_0001065 ENSG00000196208
2 rs13394619 2_11587381_G_A GCST001720 13997 Nyholt DR intron_variant 2 11587381 EFO_0001065 ENSG00000196208
3 rs77294520 2_11520829_G_C GCST004549_2 208903 Sapkota Y intergenic_variant 2 11520829 EFO_0001065 ENSG00000196208

Most of the chances you don't know the genes related to the disease. NO PROBLEM!

Lets say you want to know which SNP associate with a disease you study

import opy_targets as opy

#

ENDOMETRIOSIS_EFO_ID = 'EFO_0001065'

opy.get_SNP_df(ENDOMETRIOSIS_ID).head()

output:

variantRsId variantId studyId studySampleSize publicationFirstAuthor label chr location disease_ID gene_related
0 rs11674184 2_11581409_T_G GCST004549 208903 Sapkota Y intron_variant 2 11581409 EFO_0001065 ENSG00000196208
1 rs13394619 2_11587381_G_A GCST001720 13997 Nyholt DR intron_variant 2 11587381 EFO_0001065 ENSG00000196208
2 rs77294520 2_11520829_G_C GCST004549_2 208903 Sapkota Y intergenic_variant 2 11520829 EFO_0001065 ENSG00000196208
3 rs58502716 2_11592421_G_GAATCAC FINNGEN_R5_N14_ENDOMETRIOSIS 77257 FINNGEN_R5 intron_variant 2 11592421 EFO_0001065 ENSG00000196208

You can change parameters such as the amount of genes retrived for each disease (25 default) and the sorting method of them (genetic association). check the functions docstring.

Enjoy ;)

Paid Udemy Courses with Coupons

Freedemy Paid Udemy Courses with Coupons Steps to run pip3 install -r requirements.txt python3 free-courses.py Then you can click the Enroll Link and

GOKUL A.P 23 Dec 14, 2022
Signs the target email up to over 1000 different mailing lists to get spammed each day.

Email Bomber Say goodbye to that email Features Signs up to over 1k different mailing lists Written in python so the program is lightweight Easy to us

Loxdr 1 Nov 30, 2021
Simple tool to gather domains from crt.sh using the organization name

Domain Collector: _ _ ___ _ _ _ __| | ___ _ __ ___ __ _(_)_ __ / __\___ | |

Cyber Guy 63 Dec 24, 2022
Ghost-toolbox - Ghost's official Discord raid tool

Ghost Toolbox Ghost's official Discord raid tool. How to use Clone this repo int

G H Ø S T 10 Oct 31, 2022
IMDb + Auto + Unlimited Filter BoT

Telegram Movie Bot Features Auto Filter Manuel Filter IMDB Admin Commands Broadcast Index IMDB search Inline Search Random pics ids and User info Stat

Team AlinaX 1 Dec 03, 2021
Aio-binance-library - Async library for connecting to the Binance API on Python

aio-binance-library Async library for connecting to the Binance API on Python Th

GRinvest 10 Nov 21, 2022
🥀 Find the start of the token !

Discord Token Finder Find half of your target's token with just their ID. Install 🔧 pip install -r requeriments.txt Gui Usage 💻 Go to Discord Setti

zeytroxxx 2 Dec 22, 2021
A mass account list editor for python

Account-List-Editor This is an mass account list editor Usage Run the editor.py file with python (python3 ./editor.py) Press a button (1/2) and drag &

ExtremeDev 1 Dec 20, 2021
A discord.py code generator program. Compatible with both linux and windows.

Astro-Cord A discord.py code generator program. Compatible with both linux and windows. About This is a program made to make discord.py bot developmen

Astro Inc. 2 Dec 23, 2021
My attempt at weaponizing Discord.

MayorbotC2 This is my Discord C2 bot. There are many like it, but this one is mine. MayorbotC2 is a project I absolutely forgot about until I was pilf

Joe Helle 19 May 16, 2022
Gets instagram public username and returns usefull informations like profilepic(b64), video_urls etc.

InstaSucker Gets instagram public username and returns usefull informations like profilepic(b64), video_urls etc. Information this project contains a

Armin Amiri 5 Apr 30, 2022
Balanced API library in python.

Balanced Online Marketplace Payments v1.x requires Balanced API 1.1. Use v0.x for Balanced API 1.0. Installation pip install balanced Usage View Bala

Balanced 70 Oct 04, 2022
A discord bot thet lets you play Space invaders.

space_Invaders A discord bot thet lets you play Space invaders. It is my first discord bot... so please give any suggestions to improve it :] Commands

2 Dec 30, 2021
Open Source Discord Account Creator

Alter Token Generator Open Source Discord Account Creator This program abuses the discord api and uses the 2Captcha captcha solving service to make di

24 Dec 13, 2022
A Tool to scrape URLs for a given domain from wayback machine, Commoncrawl and OTX Alienvault

Mr_URL Mr.URL fetches known URLs for a given domain from Wayback Machine, Commoncrawl and OTX Alienvault. It also finds old versions of any given URL

Stinger 9 Sep 05, 2022
Asyncevents: a small library to help developers perform asynchronous event handling in Python

asyncevents - Asynchronous event handling for modern Python asyncevents is a small library to help developers perform asynchronous event handling in m

Mattia 5 Aug 07, 2022
SmsSender v3.0.0 - the script is designed to send free SMS to any number and with any text.

SmsSender v3.0.0 - скрипт предназначен для бесплатной отправки SMS на любой номер и с любым текстом. Возможны небольшие баги, в скором времени исправл

Андрей Сергеев 20 Dec 03, 2021
Beyonic API Python official client library simplified examples using Flask, Django and Fast API.

Beyonic API Python official client library simplified examples using Flask, Django and Fast API.

A napari plugin for visualising and interacting with electron cryotomograms

napari-subboxer A napari plugin for visualising and interacting with electron cryotomograms. Installation You can install napari-subboxer via pip: pip

3 Nov 25, 2021
Cool Discord bot for you

BountyBot Баунти – современный бот созданный с целью сделать ваш сервер лучше! В кратце В нем присутствует множество основных и интересных функций, та

Leestarb Original 1 Nov 22, 2021