tradeblocks-mcp 2.0.0-beta.2 → 2.0.1
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.
- package/dist/test-exports.js +4 -4
- package/dist/test-exports.js.map +1 -1
- package/manifest.json +1 -1
- package/package.json +1 -1
- package/server/index.js +4 -4
- package/server/index.js.map +1 -1
package/dist/test-exports.js
CHANGED
|
@@ -19584,7 +19584,7 @@ function calculateCorrelationMatrix(trades, options = {}) {
|
|
|
19584
19584
|
dateBasis = "opened",
|
|
19585
19585
|
timePeriod = "daily"
|
|
19586
19586
|
} = options;
|
|
19587
|
-
const strategyDailyReturns =
|
|
19587
|
+
const strategyDailyReturns = /* @__PURE__ */ Object.create(null);
|
|
19588
19588
|
for (const trade of trades) {
|
|
19589
19589
|
if (!trade.strategy || trade.strategy.trim() === "") {
|
|
19590
19590
|
continue;
|
|
@@ -19599,7 +19599,7 @@ function calculateCorrelationMatrix(trades, options = {}) {
|
|
|
19599
19599
|
continue;
|
|
19600
19600
|
}
|
|
19601
19601
|
if (!strategyDailyReturns[strategy]) {
|
|
19602
|
-
strategyDailyReturns[strategy] =
|
|
19602
|
+
strategyDailyReturns[strategy] = /* @__PURE__ */ Object.create(null);
|
|
19603
19603
|
}
|
|
19604
19604
|
strategyDailyReturns[strategy][dateKey] = (strategyDailyReturns[strategy][dateKey] || 0) + normalizedReturn;
|
|
19605
19605
|
}
|
|
@@ -19911,7 +19911,7 @@ function performTailRiskAnalysis(trades, options = {}) {
|
|
|
19911
19911
|
};
|
|
19912
19912
|
}
|
|
19913
19913
|
function aggregateAndAlignReturns(trades, normalization, dateBasis) {
|
|
19914
|
-
const strategyDailyReturns =
|
|
19914
|
+
const strategyDailyReturns = /* @__PURE__ */ Object.create(null);
|
|
19915
19915
|
const allDates = /* @__PURE__ */ new Set();
|
|
19916
19916
|
for (const trade of trades) {
|
|
19917
19917
|
if (!trade.strategy || trade.strategy.trim() === "") {
|
|
@@ -19931,7 +19931,7 @@ function aggregateAndAlignReturns(trades, normalization, dateBasis) {
|
|
|
19931
19931
|
continue;
|
|
19932
19932
|
}
|
|
19933
19933
|
if (!strategyDailyReturns[strategy]) {
|
|
19934
|
-
strategyDailyReturns[strategy] =
|
|
19934
|
+
strategyDailyReturns[strategy] = /* @__PURE__ */ Object.create(null);
|
|
19935
19935
|
}
|
|
19936
19936
|
strategyDailyReturns[strategy][dateKey] = (strategyDailyReturns[strategy][dateKey] || 0) + normalizedReturn;
|
|
19937
19937
|
allDates.add(dateKey);
|