Constructor
new LDServer()
Parameters:
Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
config.url |
string | The base URL for the remote data. |
||||||||||||||||||||||||||||||||||||||||
config.params |
object |
Properties
|
- Source:
- See:
Methods
combineChainBody()
The LD adapter attempts to intelligently match retrieved LD information to a request for association data earlier in the data chain. Since each layer only asks for the data needed for that layer, one LD call is sufficient to annotate many separate association tracks.
- Source:
fetchRequest()
The LDServer API is paginated, but we need all of the data to render a plot. Depaginate and combine where appropriate.
- Source:
getCacheKey(state, chain, fields) → {string}
The LD adapter caches based on region, reference panel, and population name
Parameters:
Name | Type | Description |
---|---|---|
state |
||
chain |
||
fields |
- Source:
Returns:
- Type
- string
(protected) getRefvar() → {Array.<String>}
Get the LD reference variant, which by default will be the most significant hit in the assoc results This will be used in making the original query to the LD server for pairwise LD information.
This is meant to join a single LD request to any number of association results, and to work with many kinds of API. To do this, the datasource looks for fields with special known names such as pvalue, log_pvalue, etc. If your API uses different nomenclature, an option must be specified.
- Source:
Returns:
Two strings: 1) the marker id (expected to be in chr:pos_ref/alt
format) of the reference
variant, and 2) the marker ID as it appears in the original dataset that we are joining to, so that the exact
refvar can be marked when plotting the data..
- Type
- Array.<String>
getURL()
Identify (or guess) the LD reference variant, then add query parameters to the URL to construct a query for the specified region
- Source:
normalizeResponse()
The LD API payload does not obey standard format conventions; do not try to transform it.
- Source: