{"uid":"cap_GEkPAGsHstZFVI7aa8mY0","slug":"trade-observations-numeric-row-ordering-secondary-measure-weighted-mean-7f5619ae","name":"Trade Observations — Numeric Row Ordering + Secondary-Measure Weighted Mean","description":"Trade observations — Numeric row ordering + Secondary-measure weighted mean: Numeric row ordering + Secondary-measure weighted mean for supplied trade observations records (export_amount, import_amount). Up to 200 rows; 2 independent reports using shared local analytical engines. No live lookup, prediction, professional assessment or external action. 0.01 USDC includes 2 supplied-data reports for up to 200 rows.","url":"https://market.datapackvibe.com/x402/assistant-ib26-economics-06-121?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","required":["row_id","region","date","export_amount","import_amount"],"properties":{"date":{"type":"string","default":"","pattern":"^\\d{4}-\\d{2}-\\d{2}$","maxLength":10},"region":{"type":"string","default":"","maxLength":80},"row_id":{"type":"string","default":"","maxLength":80,"minLength":1},"export_amount":{"type":["number","null"],"maximum":1000000000000,"minimum":-1000000000000},"import_amount":{"type":["number","null"],"maximum":1000000000000,"minimum":-1000000000000}},"additionalProperties":false},"default":[{"date":"2026-10-01","region":"group-a","row_id":"row-1","export_amount":10,"import_amount":1},{"date":"2026-10-02","region":"group-b","row_id":"row-2","export_amount":20,"import_amount":2},{"date":"2026-10-03","region":"group-a","row_id":"row-3","export_amount":15,"import_amount":3},{"date":"2026-10-04","region":"group-b","row_id":"row-4","export_amount":30,"import_amount":4}],"maxItems":200,"minItems":1},"field":{"enum":["export_amount","import_amount"],"type":"string","default":"export_amount"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_eDkJcD0Gh1Pk9mueI6wyz","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes numeric row ordering and secondary-measure weighted mean for up to 200 trade observation records containing export and import amounts.","exampleAgentPrompt":"Rank these trade observation rows by export_amount and compute the secondary-measure weighted mean using import_amount as the weight — I have 4 records: row-1 group-a 2026-10-01 export 10 import 1, row-2 group-b 2026-10-02 export 20 import 2, row-3 group-a 2026-10-03 export 15 import 3, row-4 group-b 2026-10-04 export 30 import 4.","exampleUseCases":[{"title":"Regional export ranking for trade report","prompt":"I have monthly trade data for 8 regions with export and import figures — can you rank all the rows by export_amount and give me the weighted mean of exports weighted by import volumes? Here are the rows: row-1 through row-8 across regions A through D from 2026-01-01 to 2026-08-01."},{"title":"Quarterly import weighted average analysis","prompt":"Take these 12 trade observation records spanning Q1 2026 across group-a and group-b regions and compute the numeric row ordering plus the secondary-measure weighted mean for import_amount — I need both analyses from the same call."},{"title":"Trade data audit before dashboard publish","prompt":"Before I publish my trade dashboard, can you run numeric row ordering and secondary-measure weighted mean on these 50 trade rows using export_amount as the primary field? Each row has a row_id, date, region, export_amount, and import_amount."}],"resultDescription":"Returns two reports for the submitted trade observation rows: (1) a numeric row ordering ranking each row by the selected measure (export_amount or import_amount), and (2) a secondary-measure weighted mean computed using the chosen field weighted against the other trade measure. Both are derived entirely from the supplied data with no external lookups.","failureModes":["Rows array empty or missing — minimum 1 row required","More than 200 rows submitted — exceeds maximum batch size","Invalid date format (must match YYYY-MM-DD pattern)","Missing required fields (row_id, region, date, export_amount, import_amount) on any row","Amount values outside allowed range (-1e12 to 1e12)","Invalid field enum value — must be 'export_amount' or 'import_amount'","Payment not received or insufficient USDC balance — x402 payment required"],"whenToPreferThis":"Choose this endpoint when you need both a numeric row ranking and a secondary-measure weighted mean computed together on trade observation data (export and import amounts) in a single API call. It is ideal for batch analytics on up to 200 trade records where no live data lookup, prediction, or external enrichment is needed — just local statistical computation on supplied rows. It saves cost versus calling two separate endpoints.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-26T12:31:37.306Z","isFirstParty":false,"canonicalSlug":"trade-observations-numeric-row-ordering-secondary-measure-weighted-mean-7f5619ae"}