I Built the World’s First Cancer Biology-Inspired Portfolio Analyzer (And Deployed It on the Blockchain)
How Glioblastoma Survival Strategies, Pancreatic Tumor Barriers, and Metastatic Dormancy Can Protect Your Investments
The Problem with Traditional Portfolio Theory
Modern Portfolio Theory tells you to diversify. The 60/40 rule suggests balance. Dollar-cost averaging preaches consistency.
But none of these frameworks answer the fundamental question: How do you build a portfolio that survives?
Not just survives bull markets. Not just survives corrections. But survives everything – black swans, regime changes, technological disruptions, and decade-long bear markets.
As a computational cancer biologist, I’ve spent years studying organisms that have perfected the art of survival: cancer cells.
Now, before you close this tab – hear me out. Cancer cells are nature’s ultimate survivors. They adapt, they diversify, they build protective barriers, and they know exactly when to go dormant and when to strike. These strategies, when translated to portfolio management, create something I call the BioFlywheel Framework.
And I just deployed it as a fully decentralized application on the Internet Computer blockchain.
Three Cancer Types, Three Investment Layers
The BioFlywheel Framework applies survival strategies from three of the deadliest cancers to create a three-layer portfolio system:
Layer 1: The GBM Heterogeneity Engine (50% allocation)
Glioblastoma multiforme (GBM) is one of the most aggressive brain cancers. Its survival secret? Extreme heterogeneity.
A single GBM tumor contains multiple subpopulations of cells with different metabolic profiles, growth rates, and treatment resistances. When one subpopulation is attacked, others survive and repopulate. This diversity is mathematically quantified using Shannon entropy – the same formula that powers information theory.
Investment Translation:
- Multiple asset classes: US equities, international stocks, small-cap value, long-term treasuries, gold, dividend growth
- Diversified strategies: Growth, value, momentum, defensive
- Mathematical scoring: Shannon entropy measures portfolio heterogeneity (0-100 scale)
- Escape pathways: Automatic reallocation triggers when growth assets decline
Holdings Example:
- VTI (US Total Market) – 10%
- VXUS (International) – 8%
- AVUV (Small Cap Value) – 7%
- TLT (Long Treasuries) – 8%
- GLD (Gold) – 7%
- SCHD (Dividend Growth) – 5%
- JEPI (Income) – 5%
Layer 2: The Pancreatic Stromal Fortress (30% allocation)
Pancreatic cancer is notoriously difficult to treat because tumors build a dense stromal barrier – a fortress of connective tissue that blocks chemotherapy drugs and immune cells.
Investment Translation:
- Ultra-safe core: Short-term treasuries (SGOV, SHV, BIL)
- Protective moat: Stable value assets that resist market volatility
- Fortress thickness metric: Percentage of portfolio in defensive positions
- Crisis thickening: Automatic increase in defensive allocation when VIX >30
Holdings Example:
- SGOV (0-3 Month Treasuries) – 10%
- SHV (Short Treasuries) – 5%
- VNQ (Real Estate) – 5%
- PDBC (Commodities) – 5%
- QVAL (Quality Value) – 3%
- DGS (Emerging Div) – 2%
Layer 3: The Metastatic Timing Engine (20% allocation)
Cancer metastasis isn’t random. Cells enter dormancy at distant sites, waiting for the right conditions to reactivate. They conserve resources, avoid detection, and strike when opportunities arise.
Investment Translation:
- Dry powder: Cash and ultra-liquid positions
- Opportunistic deployment: Capital ready for market dislocations
- Dormancy discipline: Resist the urge to be “fully invested”
- Activation signals: Predetermined triggers for capital deployment
Holdings Example:
- BIL (1-3 Month Treasuries) – 10%
- CASH (Money Market) – 10%
How the BioFlywheel Analyzer Works
I translated this framework into a blockchain-deployed application that analyzes your portfolio across all three biological layers.
Try it yourself: https://3bvys-4aaaa-aaaap-qrfua-cai.icp0.io/
What It Calculates:
1. Heterogeneity Score (0-100)
Uses Shannon entropy to measure portfolio diversity:
H = -Σ(p_i × log₂(p_i))
Where p_i is the weight of each position. Higher scores indicate better “cellular” diversity.
2. GBM Layer Score (0-100)
Evaluates:
- Growth exposure adequacy
- Escape pathway presence (defensive assets)
- Position count (should have 4+ for true heterogeneity)
- Allocation balance (target: 50%)
3. Pancreatic Fortress Score (0-100)
Measures:
- Ultra-safe core thickness
- Fortress allocation (target: 30%)
- Defensive diversity
- Protection against volatility shocks
4. Metastatic Timing Score (0-100)
Assesses:
- Liquid reserves adequacy
- Opportunistic capital availability
- Cash/near-cash allocation (target: 20%)
- Deployment readiness
5. Overall BioFlywheel Health (0-100)
Weighted average of all three layers with specific warnings for:
- Position drift from targets
- Insufficient heterogeneity
- Missing escape pathways
- Weak fortress defenses
- Inadequate activation capital
Example Analysis
Here’s a real analysis from the tool (my own portfolio):
💼 PORTFOLIO VALUE: $78,650
🧬 HETEROGENEITY: 84/100
🔬 BIOLOGICAL LAYER SCORES:
• GBM Heterogeneity Engine: 85/100
• Pancreatic Fortress: 100/100
• Metastatic Timing Engine: 100/100
📊 OVERALL HEALTH: 95/100
⚠️ WARNINGS:
🧬 Insufficient GBM heterogeneity
🔄 VTI drifted 6% from target
🔄 SGOV drifted 5% from target
💡 ANALYSIS:
✅ EXCEPTIONAL BIOFLYWHEEL HEALTH: All three biological
layers functioning optimally with strong heterogeneity.
Continue current strategy.
The 95/100 score reflects strong execution across all three cancer survival strategies. The warnings catch position drift before it becomes problematic – exactly how immune surveillance catches abnormal cells early.
Why Deploy on Blockchain?
You might wonder why I built this on the Internet Computer instead of using traditional web hosting. Three reasons:
1. Censorship Resistance
My “anti-hype” approach to investing doesn’t make me popular with financial influencers pushing speculation. A decentralized application can’t be taken down by angry crypto promoters or threatened platforms.
2. Zero Hosting Costs
After initial deployment (~$30 in ICP tokens), the application runs indefinitely with no monthly fees. The blockchain network maintains it.
3. Provable Computation
Every analysis runs on-chain with cryptographic verification. The algorithms can’t be secretly changed or manipulated. What you see is what runs.
The Math Behind the Biology
For those interested in the technical details, here’s how key calculations work:
Shannon Entropy for Heterogeneity:
def calculate_heterogeneity(weights):
"""
Shannon entropy normalized to 0-100 scale
Higher entropy = more diverse = better survival
"""
# Remove zero weights
weights = [w for w in weights if w > 0.0001]
# Calculate entropy
entropy = -sum(w * log2(w) for w in weights)
# Normalize by maximum possible entropy
max_entropy = log2(len(weights))
return (entropy / max_entropy) * 100
Metabolic Stability Scoring:
def score_metabolic_stability(stock_pct, cash_pct):
"""
Penalizes extreme allocations
Rewards balanced metabolic state
"""
score = 100.0
# Penalty for overexposure (>75% stocks)
if stock_pct > 75:
score -= (stock_pct - 75) * 3.0
# Penalty for excess cash drag (>20%)
if cash_pct > 20:
score -= (cash_pct - 20) * 2.5
# Bonus for optimal range (50-65% stocks, <15% cash)
if 50 <= stock_pct <= 65 and cash_pct <= 15:
score += 10.0
return max(0, min(100, score))
These aren’t arbitrary rules – they’re mathematical translations of biological principles observed in cancer survival.
Try It Yourself
Live Application: https://3bvys-4aaaa-aaaap-qrfua-cai.icp0.io/
The analyzer includes:
- Multi-ETF portfolio input (up to 15+ positions)
- Biological layer assignment (GBM/Pancreatic/Metastatic)
- Preset portfolios for quick testing
- Real-time Shannon entropy calculation
- Drift detection with specific warnings
- Actionable advice based on biological triggers
It’s completely free to use. No sign-up, no data collection, no ads. Just pure cancer-biology-inspired portfolio analysis.
What Makes This Different
There are thousands of portfolio analyzers. Most calculate standard deviation, Sharpe ratios, and efficient frontiers.
The BioFlywheel Framework asks a different question: What would a portfolio look like if it evolved to survive like cancer?
The answer:
- Extreme heterogeneity (not just “diversification”)
- Protective barriers (not just “defensive allocation”)
- Strategic dormancy (not just “cash on the sidelines”)
- Adaptive triggers (not just “rebalancing schedules”)
This isn’t about beating the market. It’s about outliving the market – surviving long enough to compound wealth through multiple market cycles, regime changes, and black swan events.
The Deeper Philosophy
Cancer cells don’t predict the future. They don’t try to time chemotherapy. They don’t believe they can outsmart the immune system.
Instead, they:
- Prepare for uncertainty through diversity
- Build redundancies across metabolic pathways
- Maintain reserves for resource scarcity
- Adapt quickly when conditions change
Your portfolio should do the same.
Not because markets are like cancer (they’re not). But because the mathematical principles that allow cancer to survive hostile environments also create portfolios that survive market chaos.
What’s Next for BioFlywheel
This is version 1.0. Future enhancements include:
Technical:
- Live price integration via blockchain oracles
- Historical portfolio tracking on-chain
- VIX-triggered biological response activation
- Correlation matrix analysis for “immune surveillance”
- Automated rebalancing recommendations
Educational:
- Video course: “Portfolio Biology 101”
- Advanced module: Angiogenesis analogies for capital allocation
- Research paper: Mathematical proofs of BioFlywheel resilience
Community:
- User-submitted portfolios for analysis
- BioFlywheel score leaderboard
- Quarterly “Cancer Cell Portfolio” challenges
Why I Built This
I’m tired of finance educators selling hope without methodology. I’m exhausted by crypto influencers promising 1000x returns. I’m done with “gurus” who can’t explain their frameworks mathematically.
I come from computational cancer biology. When we model tumor growth, we show our equations. When we predict treatment resistance, we quantify uncertainty. When we design therapies, we understand failure modes.
Finance should be the same.
The BioFlywheel Framework is my answer: a mathematically rigorous, biologically inspired, blockchain-deployed approach to portfolio construction that prioritizes survival over speculation.
Try the BioFlywheel Analyzer
Live Tool: https://3bvys-4aaaa-aaaap-qrfua-cai.icp0.io/
Enter your portfolio. Get your heterogeneity score. See how your biological layers stack up. Receive specific warnings about metabolic instability, fortress weakness, or insufficient activation capital.
It takes 2 minutes and might change how you think about portfolio construction forever.
Connect & Learn More
- Website: equationsinkala.com
If you’re interested in the mathematics behind this framework, I’m working on a book: “Advanced Mathematics for Everyday Thinking: A Computational Biologist’s Approach to Finance.”
P.S. – If you try the analyzer, share your heterogeneity score on social media with #BioFlywheelPortfolio. Let’s see who’s built the most “cancer-resistant” portfolio!
Zach is a computational cancer biologist who applies mathematical modeling from oncology research to financial education. He runs equationsinkala.com and is developing the BioFlywheel Framework for anti-fragile portfolio construction.
Technical Notes for Developers
For those interested in the blockchain implementation:
Backend: Motoko smart contract on Internet Computer
Frontend: JavaScript with Internet Computer Agent
Canister IDs:
- Backend:
3ntsz-tqaaa-aaaal-qttbq-cai - Frontend:
3bvys-4aaaa-aaaap-qrfua-cai
Key Algorithms:
- Shannon entropy calculation (O(n) complexity)
- Layer-wise scoring with biological thresholds
- Drift detection with configurable tolerance
- Biological trigger identification
Open Questions for Community:
- Should metastatic layer include crypto exposure?
- What VIX level optimally triggers fortress thickening?
- How to model “tumor microenvironment” for sector correlations?
Code repository coming soon for developers who want to fork and extend the framework.
Ready to build a portfolio that survives like cancer? Try the BioFlywheel Analyzer →