pharmaobservatory 0.1.14 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module PharmaObservatory
17
- # One row of the company_competitors dataset: one row per ordered company pair: a company and one of the top 25 companies of each competitor_class by program overlap. A grouped request returns the group columns and the measures instead, as additional properties.
17
+ # One row of the company_competitors dataset: one row per ordered company pair: an industry company and one of its top 25 industry competitors by asset collision. A grouped request returns the group columns and the measures instead, as additional properties.
18
18
  class CompanyCompetitorsRow
19
19
  # Company level: the company the row is about; the entry key for the companies object type.
20
20
  attr_accessor :company_id
@@ -40,62 +40,44 @@ module PharmaObservatory
40
40
  # Display name of the competitor's group.
41
41
  attr_accessor :competitor_group_name
42
42
 
43
- # The competitor's class: industry, or non_industry (not classed as industry by the sponsor-class rule: academic, hospital, government, nonprofit, and any record the rule does not reach). competitor_rank restarts at 1 within each class, so filter or sort on this column first.
43
+ # The competitor's class: always industry since the not-classed-as-industry group left Competitors; the column is kept so a query written against it keeps working. competitor_rank is 1-based within the class.
44
44
  attr_accessor :competitor_class
45
45
 
46
- # How many companies of this competitor_class were candidates (a shared target, or an indication overlap above the similarity floor) before the top 25 were kept. The same value on every row of one company and class.
46
+ # How many companies of this competitor_class had at least one asset collision with the company before the top 25 were kept. The same value on every row of one company and class.
47
47
  attr_accessor :n_class_candidates
48
48
 
49
49
  # The competitor's rank within its competitor_class for the company by competitor_score (1 is the highest).
50
50
  attr_accessor :competitor_rank
51
51
 
52
- # 100 times the weighted mean of the four similarities below, rounded to four places.
52
+ # The weighted share of the company's live target families that the competitor's live assets collide with, 0 to 100, rounded to four places. Each colliding family counts its best collision weight (rarity of the family across companies, times factors for same action, a shared indication, the least advanced stage, recency and a head-to-head trial), capped at the family's rarity weight; the sum is divided by the rarity weights of ALL the company's families.
53
53
  attr_accessor :competitor_score
54
54
 
55
- # Jaccard similarity, 0 to 1, of the two companies' molecular target sets.
56
- attr_accessor :target_sim
55
+ # Asset pairs (a drug of the company, a drug of the competitor) that act on a common target.
56
+ attr_accessor :n_collisions
57
57
 
58
- # Jaccard similarity, 0 to 1, of their mechanism sets (a target and its action).
59
- attr_accessor :mechanism_sim
58
+ # Target families of the company's live assets that the competitor collides with.
59
+ attr_accessor :n_colliding_families
60
60
 
61
- # Jaccard similarity, 0 to 1, of their top-25 disease area sets.
62
- attr_accessor :indication_sim
61
+ # Target families of the company's own live, owned assets; the denominator of competitor_score is their rarity weights.
62
+ attr_accessor :n_subject_families
63
63
 
64
- # The fraction, 0 to 1, of the shared targets that both companies have taken to phase 2 or later.
65
- attr_accessor :phase_sim
64
+ # Asset pairs whose drugs act on the shared target with the same action type.
65
+ attr_accessor :n_same_action
66
66
 
67
- # Molecular targets both companies pursue.
68
- attr_accessor :n_shared_targets
67
+ # Asset pairs whose programs share at least one disease area. Every listed pair does, so it equals n_collisions.
68
+ attr_accessor :n_shared_indication_pairs
69
69
 
70
- # Mechanisms (target and action) both companies pursue.
71
- attr_accessor :n_shared_mechanisms
70
+ # Distinct trials led by either company in which one drug of a pair is experimental and the other an active comparator.
71
+ attr_accessor :n_head_to_head_trials
72
72
 
73
- # Disease areas both companies are in, within each one's top 25.
74
- attr_accessor :n_shared_indications
73
+ # The most advanced pair's stage, where a pair's stage is the less advanced of its two programs' furthest phase: 6 Phase 4, 5 Phase 3, 4 Phase 2/3, 3 Phase 2, 2 Phase 1/2, 1 Phase 1, 0 Early Phase 1, -1 phase not applicable. A tie-break key after the score.
74
+ attr_accessor :best_stage
75
75
 
76
- # Shared targets that both companies have taken to phase 2 or later.
77
- attr_accessor :n_phase_overlap_targets
76
+ # The latest trial start year over the company pair's programs (the maximum over its asset pairs of the later of the two programs' last start year). A tie-break key after the score; null when no program has a start year.
77
+ attr_accessor :last_year
78
78
 
79
- # Targets the company pursues (the Jaccard denominator).
80
- attr_accessor :n_company_targets
81
-
82
- # Targets the competitor pursues.
83
- attr_accessor :n_competitor_targets
84
-
85
- # Disease areas in the company's top 25.
86
- attr_accessor :n_company_indications
87
-
88
- # Disease areas in the competitor's top 25.
89
- attr_accessor :n_competitor_indications
90
-
91
- # Up to 5 shared target gene symbols, by combined phase then combined trials. An empty list when none.
92
- attr_accessor :top_shared_targets
93
-
94
- # Up to 5 shared disease area names, by combined trial count. An empty list when none.
95
- attr_accessor :top_shared_indications
96
-
97
- # Up to 3 shared mechanisms written as a gene symbol and an action, by combined phase then combined trials. An empty list when none.
98
- attr_accessor :top_shared_mechanisms
79
+ # Up to 3 strongest asset pairs as text: \"drug A / drug B: target family, stage, N shared indications\". The stage is the less advanced of the two programs. An ownership_basis of inferred_lead on the underlying pair (see company_asset_collisions) is an inference.
80
+ attr_accessor :top_collisions
99
81
 
100
82
  # Distinct trials on which the company and the competitor are both named as sponsors, counted over their subtrees; 0 when none. A consortium trial (more than 25 sponsor companies) is left out.
101
83
  attr_accessor :n_cosponsored_trials
@@ -115,21 +97,15 @@ module PharmaObservatory
115
97
  :'n_class_candidates' => :'n_class_candidates',
116
98
  :'competitor_rank' => :'competitor_rank',
117
99
  :'competitor_score' => :'competitor_score',
118
- :'target_sim' => :'target_sim',
119
- :'mechanism_sim' => :'mechanism_sim',
120
- :'indication_sim' => :'indication_sim',
121
- :'phase_sim' => :'phase_sim',
122
- :'n_shared_targets' => :'n_shared_targets',
123
- :'n_shared_mechanisms' => :'n_shared_mechanisms',
124
- :'n_shared_indications' => :'n_shared_indications',
125
- :'n_phase_overlap_targets' => :'n_phase_overlap_targets',
126
- :'n_company_targets' => :'n_company_targets',
127
- :'n_competitor_targets' => :'n_competitor_targets',
128
- :'n_company_indications' => :'n_company_indications',
129
- :'n_competitor_indications' => :'n_competitor_indications',
130
- :'top_shared_targets' => :'top_shared_targets',
131
- :'top_shared_indications' => :'top_shared_indications',
132
- :'top_shared_mechanisms' => :'top_shared_mechanisms',
100
+ :'n_collisions' => :'n_collisions',
101
+ :'n_colliding_families' => :'n_colliding_families',
102
+ :'n_subject_families' => :'n_subject_families',
103
+ :'n_same_action' => :'n_same_action',
104
+ :'n_shared_indication_pairs' => :'n_shared_indication_pairs',
105
+ :'n_head_to_head_trials' => :'n_head_to_head_trials',
106
+ :'best_stage' => :'best_stage',
107
+ :'last_year' => :'last_year',
108
+ :'top_collisions' => :'top_collisions',
133
109
  :'n_cosponsored_trials' => :'n_cosponsored_trials'
134
110
  }
135
111
  end
@@ -159,21 +135,15 @@ module PharmaObservatory
159
135
  :'n_class_candidates' => :'Integer',
160
136
  :'competitor_rank' => :'Integer',
161
137
  :'competitor_score' => :'Float',
162
- :'target_sim' => :'Float',
163
- :'mechanism_sim' => :'Float',
164
- :'indication_sim' => :'Float',
165
- :'phase_sim' => :'Float',
166
- :'n_shared_targets' => :'Integer',
167
- :'n_shared_mechanisms' => :'Integer',
168
- :'n_shared_indications' => :'Integer',
169
- :'n_phase_overlap_targets' => :'Integer',
170
- :'n_company_targets' => :'Integer',
171
- :'n_competitor_targets' => :'Integer',
172
- :'n_company_indications' => :'Integer',
173
- :'n_competitor_indications' => :'Integer',
174
- :'top_shared_targets' => :'Array<String>',
175
- :'top_shared_indications' => :'Array<String>',
176
- :'top_shared_mechanisms' => :'Array<String>',
138
+ :'n_collisions' => :'Integer',
139
+ :'n_colliding_families' => :'Integer',
140
+ :'n_subject_families' => :'Integer',
141
+ :'n_same_action' => :'Integer',
142
+ :'n_shared_indication_pairs' => :'Integer',
143
+ :'n_head_to_head_trials' => :'Integer',
144
+ :'best_stage' => :'Integer',
145
+ :'last_year' => :'Integer',
146
+ :'top_collisions' => :'Array<String>',
177
147
  :'n_cosponsored_trials' => :'Integer'
178
148
  }
179
149
  end
@@ -193,21 +163,15 @@ module PharmaObservatory
193
163
  :'n_class_candidates',
194
164
  :'competitor_rank',
195
165
  :'competitor_score',
196
- :'target_sim',
197
- :'mechanism_sim',
198
- :'indication_sim',
199
- :'phase_sim',
200
- :'n_shared_targets',
201
- :'n_shared_mechanisms',
202
- :'n_shared_indications',
203
- :'n_phase_overlap_targets',
204
- :'n_company_targets',
205
- :'n_competitor_targets',
206
- :'n_company_indications',
207
- :'n_competitor_indications',
208
- :'top_shared_targets',
209
- :'top_shared_indications',
210
- :'top_shared_mechanisms',
166
+ :'n_collisions',
167
+ :'n_colliding_families',
168
+ :'n_subject_families',
169
+ :'n_same_action',
170
+ :'n_shared_indication_pairs',
171
+ :'n_head_to_head_trials',
172
+ :'best_stage',
173
+ :'last_year',
174
+ :'top_collisions',
211
175
  :'n_cosponsored_trials'
212
176
  ])
213
177
  end
@@ -276,69 +240,41 @@ module PharmaObservatory
276
240
  self.competitor_score = attributes[:'competitor_score']
277
241
  end
278
242
 
279
- if attributes.key?(:'target_sim')
280
- self.target_sim = attributes[:'target_sim']
281
- end
282
-
283
- if attributes.key?(:'mechanism_sim')
284
- self.mechanism_sim = attributes[:'mechanism_sim']
285
- end
286
-
287
- if attributes.key?(:'indication_sim')
288
- self.indication_sim = attributes[:'indication_sim']
243
+ if attributes.key?(:'n_collisions')
244
+ self.n_collisions = attributes[:'n_collisions']
289
245
  end
290
246
 
291
- if attributes.key?(:'phase_sim')
292
- self.phase_sim = attributes[:'phase_sim']
247
+ if attributes.key?(:'n_colliding_families')
248
+ self.n_colliding_families = attributes[:'n_colliding_families']
293
249
  end
294
250
 
295
- if attributes.key?(:'n_shared_targets')
296
- self.n_shared_targets = attributes[:'n_shared_targets']
251
+ if attributes.key?(:'n_subject_families')
252
+ self.n_subject_families = attributes[:'n_subject_families']
297
253
  end
298
254
 
299
- if attributes.key?(:'n_shared_mechanisms')
300
- self.n_shared_mechanisms = attributes[:'n_shared_mechanisms']
255
+ if attributes.key?(:'n_same_action')
256
+ self.n_same_action = attributes[:'n_same_action']
301
257
  end
302
258
 
303
- if attributes.key?(:'n_shared_indications')
304
- self.n_shared_indications = attributes[:'n_shared_indications']
259
+ if attributes.key?(:'n_shared_indication_pairs')
260
+ self.n_shared_indication_pairs = attributes[:'n_shared_indication_pairs']
305
261
  end
306
262
 
307
- if attributes.key?(:'n_phase_overlap_targets')
308
- self.n_phase_overlap_targets = attributes[:'n_phase_overlap_targets']
263
+ if attributes.key?(:'n_head_to_head_trials')
264
+ self.n_head_to_head_trials = attributes[:'n_head_to_head_trials']
309
265
  end
310
266
 
311
- if attributes.key?(:'n_company_targets')
312
- self.n_company_targets = attributes[:'n_company_targets']
267
+ if attributes.key?(:'best_stage')
268
+ self.best_stage = attributes[:'best_stage']
313
269
  end
314
270
 
315
- if attributes.key?(:'n_competitor_targets')
316
- self.n_competitor_targets = attributes[:'n_competitor_targets']
317
- end
318
-
319
- if attributes.key?(:'n_company_indications')
320
- self.n_company_indications = attributes[:'n_company_indications']
321
- end
322
-
323
- if attributes.key?(:'n_competitor_indications')
324
- self.n_competitor_indications = attributes[:'n_competitor_indications']
325
- end
326
-
327
- if attributes.key?(:'top_shared_targets')
328
- if (value = attributes[:'top_shared_targets']).is_a?(Array)
329
- self.top_shared_targets = value
330
- end
331
- end
332
-
333
- if attributes.key?(:'top_shared_indications')
334
- if (value = attributes[:'top_shared_indications']).is_a?(Array)
335
- self.top_shared_indications = value
336
- end
271
+ if attributes.key?(:'last_year')
272
+ self.last_year = attributes[:'last_year']
337
273
  end
338
274
 
339
- if attributes.key?(:'top_shared_mechanisms')
340
- if (value = attributes[:'top_shared_mechanisms']).is_a?(Array)
341
- self.top_shared_mechanisms = value
275
+ if attributes.key?(:'top_collisions')
276
+ if (value = attributes[:'top_collisions']).is_a?(Array)
277
+ self.top_collisions = value
342
278
  end
343
279
  end
344
280
 
@@ -379,21 +315,15 @@ module PharmaObservatory
379
315
  n_class_candidates == o.n_class_candidates &&
380
316
  competitor_rank == o.competitor_rank &&
381
317
  competitor_score == o.competitor_score &&
382
- target_sim == o.target_sim &&
383
- mechanism_sim == o.mechanism_sim &&
384
- indication_sim == o.indication_sim &&
385
- phase_sim == o.phase_sim &&
386
- n_shared_targets == o.n_shared_targets &&
387
- n_shared_mechanisms == o.n_shared_mechanisms &&
388
- n_shared_indications == o.n_shared_indications &&
389
- n_phase_overlap_targets == o.n_phase_overlap_targets &&
390
- n_company_targets == o.n_company_targets &&
391
- n_competitor_targets == o.n_competitor_targets &&
392
- n_company_indications == o.n_company_indications &&
393
- n_competitor_indications == o.n_competitor_indications &&
394
- top_shared_targets == o.top_shared_targets &&
395
- top_shared_indications == o.top_shared_indications &&
396
- top_shared_mechanisms == o.top_shared_mechanisms &&
318
+ n_collisions == o.n_collisions &&
319
+ n_colliding_families == o.n_colliding_families &&
320
+ n_subject_families == o.n_subject_families &&
321
+ n_same_action == o.n_same_action &&
322
+ n_shared_indication_pairs == o.n_shared_indication_pairs &&
323
+ n_head_to_head_trials == o.n_head_to_head_trials &&
324
+ best_stage == o.best_stage &&
325
+ last_year == o.last_year &&
326
+ top_collisions == o.top_collisions &&
397
327
  n_cosponsored_trials == o.n_cosponsored_trials
398
328
  end
399
329
 
@@ -406,7 +336,7 @@ module PharmaObservatory
406
336
  # Calculates hash code according to all attributes.
407
337
  # @return [Integer] Hash code
408
338
  def hash
409
- [company_id, company_name, group_id, group_name, competitor_company_id, competitor_company_name, competitor_group_id, competitor_group_name, competitor_class, n_class_candidates, competitor_rank, competitor_score, target_sim, mechanism_sim, indication_sim, phase_sim, n_shared_targets, n_shared_mechanisms, n_shared_indications, n_phase_overlap_targets, n_company_targets, n_competitor_targets, n_company_indications, n_competitor_indications, top_shared_targets, top_shared_indications, top_shared_mechanisms, n_cosponsored_trials].hash
339
+ [company_id, company_name, group_id, group_name, competitor_company_id, competitor_company_name, competitor_group_id, competitor_group_name, competitor_class, n_class_candidates, competitor_rank, competitor_score, n_collisions, n_colliding_families, n_subject_families, n_same_action, n_shared_indication_pairs, n_head_to_head_trials, best_stage, last_year, top_collisions, n_cosponsored_trials].hash
410
340
  end
411
341
 
412
342
  # Builds the object from hash
@@ -11,5 +11,5 @@ Generator version: 7.13.0
11
11
  =end
12
12
 
13
13
  module PharmaObservatory
14
- VERSION = '0.1.14'
14
+ VERSION = '0.1.16'
15
15
  end
@@ -82,6 +82,8 @@ require 'pharmaobservatory/models/companies_record'
82
82
  require 'pharmaobservatory/models/companies_record_attributes'
83
83
  require 'pharmaobservatory/models/companies_response'
84
84
  require 'pharmaobservatory/models/companies_row'
85
+ require 'pharmaobservatory/models/company_asset_collisions_response'
86
+ require 'pharmaobservatory/models/company_asset_collisions_row'
85
87
  require 'pharmaobservatory/models/company_assets_response'
86
88
  require 'pharmaobservatory/models/company_assets_row'
87
89
  require 'pharmaobservatory/models/company_biomarker_capability_response'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pharmaobservatory
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.14
4
+ version: 0.1.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scientist.com
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-11-04 00:00:00.000000000 Z
11
+ date: 2026-11-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -156,6 +156,8 @@ files:
156
156
  - docs/CompaniesRecordAttributes.md
157
157
  - docs/CompaniesResponse.md
158
158
  - docs/CompaniesRow.md
159
+ - docs/CompanyAssetCollisionsResponse.md
160
+ - docs/CompanyAssetCollisionsRow.md
159
161
  - docs/CompanyAssetsResponse.md
160
162
  - docs/CompanyAssetsRow.md
161
163
  - docs/CompanyBiomarkerCapabilityResponse.md
@@ -677,6 +679,8 @@ files:
677
679
  - lib/pharmaobservatory/models/companies_record_attributes.rb
678
680
  - lib/pharmaobservatory/models/companies_response.rb
679
681
  - lib/pharmaobservatory/models/companies_row.rb
682
+ - lib/pharmaobservatory/models/company_asset_collisions_response.rb
683
+ - lib/pharmaobservatory/models/company_asset_collisions_row.rb
680
684
  - lib/pharmaobservatory/models/company_assets_response.rb
681
685
  - lib/pharmaobservatory/models/company_assets_row.rb
682
686
  - lib/pharmaobservatory/models/company_biomarker_capability_response.rb