Get average drug price per ATC category, per country (LinkedDrugs)

Get average drug price per ATC category, per country (LinkedDrugs)

Endpoint: FINKI

Added by milos.jovanovik

Query:

prefix schema: <http://schema.org/> prefix drugbank: <http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/> SELECT (?totalCost / ?drugCount as ?averageCost) ?costCurrency ?atc ?drugCount ?country WHERE { SELECT count (distinct ?drug) as ?drugCount sum (xsd:float(?cost)) as ?totalCost ?costCurrency ?atc ?country FROM <http://linkeddata.finki.ukim.mk/lod/data/drugs#> WHERE { ?drug a schema:Drug ; schema:addressCountry ?country ; drugbank:atcCode ?atcCode ; schema:cost ?costEntity . ?costEntity schema:costPerUnit ?costPerUnit ; schema:costCurrency ?costCurrency . FILTER (strlen(?atcCode) > 3) BIND(SUBSTR(xsd:string(?atcCode), 1, 3) AS ?atc) FILTER (?costPerUnit != "0"^^xsd:double) BIND(REPLACE(?costPerUnit, ",", ".") AS ?cost) } } GROUP BY ?country ?atc ?costCurrency ORDER BY DESC (?averageCost) LIMIT 50

Last run: 10 months ago Run Now

Results:

Total: 50

averageCost costCurrency atc drugCount country
1. 93480.5 NOK M09 4 NO
2. 47221.5 NOK R07 19 NO
3. 39557.3 NOK A16 31 NO
4. 32021.5 MKD A16 15 MK
5. 28837.2 MKD H01 12 MK
6. 27478.2 MKD B02 29 MK
7. 24468.8 MKD J05 20 MK
8. 23329.4 NOK J04 11 NO
9. 22500.0 AUD R07 1 AU
10. 21871.7 MKD L01 228 MK
11. 18223.1 MKD L04 39 MK
12. 17909.3 MKD R07 4 MK
13. 17822.0 SVN R07 1 SI
14. 17659.9 MKD L03 29 MK
15. 17388.8 MKD J06 19 MK
16. 14809.0 NOK B06 6 NO
17. 14545.0 MKD V03 15 MK
18. 14079.0 MKD V08 17 MK
19. 13360.1 EUR V10 1 CY
20. 11641.5 NOK V07 1 NO
21. 10679.5 ZAR LO4 93 ZA
22. 10531.5 NOK L01 397 NO
23. 10375.0 ZAR   L 94 ZA
24. 10145.5 NOK L04 133 NO
25. 10127.1 ZAR B06 4 ZA
26. 9950.25 NOK L03 28 NO
27. 9880.81 ZAR A16 6 ZA
28. 9051.27 NOK H01 70 NO
29. 8947.94 MKD M05 47 MK
30. 8718.61 MKD L02 39 MK
31. 8696.16 NOK C02 36 NO
32. 8256.03 ZAR L04 93 ZA
33. 8117.04 MKD M03 7 MK
34. 7846.94 NOK V09 61 NO
35. 7432.02 NOK J06 47 NO
36. 7358.57 ZAR L03 32 ZA
37. 7277.27 MKD B03 43 MK
38. 6753.98 ZAR L01 413 ZA
39. 6444.18 ZAR V10 57 ZA
40. 6121.42 ZAR H01 30 ZA
41. 6108.56 MKD B01 57 MK
42. 6054.01 NOK V03 54 NO
43. 5800.87 NOK V10 44 NO
44. 5784.5 ZAR V09 56 ZA
45. 5748.82 MKD J07 30 MK
46. 5654.82 NOK B01 128 NO
47. 5425.1 ZAR R07 7 ZA
48. 5102.38 ZAR B02 37 ZA
49. 4905.38 NOK B02 39 NO
50. 4434.27 SVN V10 1 SI