# How to modify data source weights in the API?

**URL:** <https://community.opentargets.org/t/how-to-modify-data-source-weights-in-the-api/1064>\
**Category:** GraphQL API\
**Tags:** ot-platform\
**Created:** [28 April 2023 13:05 UTC](https://community.opentargets.org/t/how-to-modify-data-source-weights-in-the-api/1064 "2023-04-28T13:05:51Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![irene](https://dub1.discourse-cdn.com/flex017/user_avatar/community.opentargets.org/irene/32/50_2.png) [@irene](https://community.opentargets.org/u/irene)\
**Post date:** [23 August 2023 07:27 UTC](https://community.opentargets.org/t/how-to-modify-data-source-weights-in-the-api/1064/4 "2023-08-23T07:27:55Z")

</div>

Hi @cjb-apis and welcome to our Community!

1. Regarding the weights and association scores  
You are right in observing that amending the weights using the `datasources` parameter in your query directly impacts the overall association score. The purpose behind this design is that these weights are applied to each datasource when combining the associations by datasource. _Only when these are combined do we compute the associations by datatype or the overall associations_. Until that point, they aren’t considered, and hence the API doesn’t return weighted associations by datasource. As described in our documentation:

> “To calculate both data type and overall association scores, evidence is weighted using a factor that aims to calibrate the relevance of each data source relative to others.”

1. The propagate boolean  
The `propagate` boolean determines if the evidence from a given data source should be propagated using the ontology. You can learn more about it [here](https://platform-docs.opentargets.org/associations#ontological-selection-of-evidence). If you set `propagate` to `true`, it means you’re allowing this ontological propagation for that specific datasource in your query. To provide more context, the default values for all datasources with respect to the propagate boolean can be obtained using the following query:

```auto
query associatedTargets {
  disease(efoId: "EFO_0000349") {
    id
    name
    associatedTargets {
      datasources {
        id
        weight
        propagate
      }
    }
  }
}

```

By default, `propagate` is set to `True` for all data sources, except for Expression Atlas (RNA Expression), as mentioned in our documentation.

I hope you found this helpful! We understand the complexity of our API schema, we will work on documenting an accurate description of each endpoint. Let us know if you have further questions.

Best,  
Irene

---

_[View the full topic](https://community.opentargets.org/t/how-to-modify-data-source-weights-in-the-api/1064)._
