{"id":490,"date":"2026-08-09T12:55:27","date_gmt":"2026-08-09T12:55:27","guid":{"rendered":"https:\/\/www.stockmaster.in\/universe\/?p=490"},"modified":"2026-08-09T12:59:32","modified_gmt":"2026-08-09T12:59:32","slug":"fno-option-strategy-builder","status":"publish","type":"post","link":"https:\/\/www.stockmaster.in\/universe\/fno-option-strategy-builder\/","title":{"rendered":"F&#038;O Option Strategy Builder"},"content":{"rendered":"<div class=\"smos-tool\">\r\n\r\n  <div class=\"smos-header\">\r\n\r\n    <div class=\"smos-badge\">\r\n      STOCKMASTER UNIVERSE\r\n    <\/div>\r\n\r\n    <h2>F&amp;O Option Strategy Builder<\/h2>\r\n\r\n    <p>\r\n      Build multi-leg option strategies and analyse expiry profit,\r\n      loss, breakeven levels and payoff across different underlying prices.\r\n    <\/p>\r\n\r\n  <\/div>\r\n\r\n\r\n  <div class=\"smos-body\">\r\n\r\n\r\n    <!-- BASIC SETTINGS -->\r\n\r\n    <div class=\"smos-section-title\">\r\n      <span>1<\/span>\r\n      Strategy Settings\r\n    <\/div>\r\n\r\n\r\n    <div class=\"smos-grid\">\r\n\r\n      <div class=\"smos-field\">\r\n\r\n        <label>Current \/ Reference Price (\u20b9)<\/label>\r\n\r\n        <input\r\n          type=\"number\"\r\n          class=\"smos-spot\"\r\n          value=\"25000\"\r\n          min=\"0\"\r\n          step=\"0.01\">\r\n\r\n      <\/div>\r\n\r\n\r\n      <div class=\"smos-field\">\r\n\r\n        <label>Lot Size<\/label>\r\n\r\n        <input\r\n          type=\"number\"\r\n          class=\"smos-lot\"\r\n          value=\"75\"\r\n          min=\"1\"\r\n          step=\"1\">\r\n\r\n      <\/div>\r\n\r\n\r\n      <div class=\"smos-field\">\r\n\r\n        <label>Chart Range (%)<\/label>\r\n\r\n        <select class=\"smos-range\">\r\n\r\n          <option value=\"10\">\u00b110%<\/option>\r\n          <option value=\"15\">\u00b115%<\/option>\r\n          <option value=\"20\" selected>\u00b120%<\/option>\r\n          <option value=\"30\">\u00b130%<\/option>\r\n          <option value=\"50\">\u00b150%<\/option>\r\n\r\n        <\/select>\r\n\r\n      <\/div>\r\n\r\n\r\n      <div class=\"smos-field\">\r\n\r\n        <label>Price Steps<\/label>\r\n\r\n        <select class=\"smos-steps\">\r\n\r\n          <option value=\"41\">41<\/option>\r\n          <option value=\"61\" selected>61<\/option>\r\n          <option value=\"81\">81<\/option>\r\n          <option value=\"101\">101<\/option>\r\n\r\n        <\/select>\r\n\r\n      <\/div>\r\n\r\n    <\/div>\r\n\r\n\r\n    <!-- LEGS -->\r\n\r\n    <div class=\"smos-section-title smos-space\">\r\n\r\n      <span>2<\/span>\r\n      Option Legs\r\n\r\n    <\/div>\r\n\r\n\r\n    <div class=\"smos-leg-table-wrap\">\r\n\r\n      <table class=\"smos-leg-table\">\r\n\r\n        <thead>\r\n\r\n          <tr>\r\n\r\n            <th>Leg<\/th>\r\n            <th>Action<\/th>\r\n            <th>Type<\/th>\r\n            <th>Strike<\/th>\r\n            <th>Premium<\/th>\r\n            <th>Lots<\/th>\r\n            <th><\/th>\r\n\r\n          <\/tr>\r\n\r\n        <\/thead>\r\n\r\n\r\n        <tbody class=\"smos-legs\">\r\n\r\n\r\n          <!-- LEG 1 -->\r\n\r\n          <tr class=\"smos-leg\">\r\n\r\n            <td data-label=\"Leg\">\r\n              <strong>1<\/strong>\r\n            <\/td>\r\n\r\n            <td data-label=\"Action\">\r\n\r\n              <select class=\"smos-action\">\r\n\r\n                <option value=\"buy\">\r\n                  Buy\r\n                <\/option>\r\n\r\n                <option value=\"sell\">\r\n                  Sell\r\n                <\/option>\r\n\r\n              <\/select>\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Type\">\r\n\r\n              <select class=\"smos-type\">\r\n\r\n                <option value=\"call\">\r\n                  Call\r\n                <\/option>\r\n\r\n                <option value=\"put\">\r\n                  Put\r\n                <\/option>\r\n\r\n              <\/select>\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Strike\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-strike\"\r\n                value=\"25000\"\r\n                min=\"0\"\r\n                step=\"0.01\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Premium\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-premium\"\r\n                value=\"250\"\r\n                min=\"0\"\r\n                step=\"0.01\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Lots\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-qty\"\r\n                value=\"1\"\r\n                min=\"1\"\r\n                step=\"1\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td>\r\n\r\n              <button\r\n                type=\"button\"\r\n                class=\"smos-remove\"\r\n                disabled>\r\n\r\n                \u00d7\r\n\r\n              <\/button>\r\n\r\n            <\/td>\r\n\r\n          <\/tr>\r\n\r\n\r\n          <!-- LEG 2 -->\r\n\r\n          <tr class=\"smos-leg\">\r\n\r\n            <td data-label=\"Leg\">\r\n              <strong>2<\/strong>\r\n            <\/td>\r\n\r\n            <td data-label=\"Action\">\r\n\r\n              <select class=\"smos-action\">\r\n\r\n                <option value=\"sell\">\r\n                  Sell\r\n                <\/option>\r\n\r\n                <option value=\"buy\">\r\n                  Buy\r\n                <\/option>\r\n\r\n              <\/select>\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Type\">\r\n\r\n              <select class=\"smos-type\">\r\n\r\n                <option value=\"call\">\r\n                  Call\r\n                <\/option>\r\n\r\n                <option value=\"put\">\r\n                  Put\r\n                <\/option>\r\n\r\n              <\/select>\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Strike\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-strike\"\r\n                value=\"25500\"\r\n                min=\"0\"\r\n                step=\"0.01\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Premium\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-premium\"\r\n                value=\"100\"\r\n                min=\"0\"\r\n                step=\"0.01\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td data-label=\"Lots\">\r\n\r\n              <input\r\n                type=\"number\"\r\n                class=\"smos-qty\"\r\n                value=\"1\"\r\n                min=\"1\"\r\n                step=\"1\">\r\n\r\n            <\/td>\r\n\r\n\r\n            <td>\r\n\r\n              <button\r\n                type=\"button\"\r\n                class=\"smos-remove\">\r\n\r\n                \u00d7\r\n\r\n              <\/button>\r\n\r\n            <\/td>\r\n\r\n          <\/tr>\r\n\r\n        <\/tbody>\r\n\r\n      <\/table>\r\n\r\n    <\/div>\r\n\r\n\r\n    <div class=\"smos-buttons\">\r\n\r\n      <button\r\n        type=\"button\"\r\n        class=\"smos-add\">\r\n\r\n        + Add Option Leg\r\n\r\n      <\/button>\r\n\r\n\r\n      <button\r\n        type=\"button\"\r\n        class=\"smos-clear\">\r\n\r\n        Clear All Legs\r\n\r\n      <\/button>\r\n\r\n    <\/div>\r\n\r\n\r\n    <button\r\n      type=\"button\"\r\n      class=\"smos-build\">\r\n\r\n      Build Strategy &amp; Calculate Payoff\r\n\r\n    <\/button>\r\n\r\n\r\n    <div class=\"smos-error\"><\/div>\r\n\r\n\r\n    <!-- RESULTS -->\r\n\r\n    <div class=\"smos-results\">\r\n\r\n\r\n      <!-- STRATEGY NAME -->\r\n\r\n      <div class=\"smos-strategy-box\">\r\n\r\n        <div>\r\n\r\n          <small>Strategy Profile<\/small>\r\n\r\n          <strong class=\"smos-strategy-name\">\r\n            Custom Option Strategy\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div>\r\n\r\n          <small>Bias<\/small>\r\n\r\n          <strong class=\"smos-bias\">\r\n            Neutral\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n      <\/div>\r\n\r\n\r\n      <!-- KEY RESULTS -->\r\n\r\n      <div class=\"smos-section-title smos-result-title\">\r\n\r\n        <span>3<\/span>\r\n        Strategy Analysis\r\n\r\n      <\/div>\r\n\r\n\r\n      <div class=\"smos-result-grid\">\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Net Premium<\/small>\r\n\r\n          <strong class=\"smos-net-premium\">\r\n            \u20b90\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card smos-profit-card\">\r\n\r\n          <small>Maximum Profit<\/small>\r\n\r\n          <strong class=\"smos-max-profit\">\r\n            \u20b90\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card smos-loss-card\">\r\n\r\n          <small>Maximum Loss<\/small>\r\n\r\n          <strong class=\"smos-max-loss\">\r\n            \u20b90\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Breakeven(s)<\/small>\r\n\r\n          <strong class=\"smos-breakeven\">\r\n            \u2014\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Total Lots<\/small>\r\n\r\n          <strong class=\"smos-total-lots\">\r\n            0\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Total Contracts<\/small>\r\n\r\n          <strong class=\"smos-contracts\">\r\n            0\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Max Profit \/ Unit<\/small>\r\n\r\n          <strong class=\"smos-max-profit-unit\">\r\n            \u20b90\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n\r\n        <div class=\"smos-card\">\r\n\r\n          <small>Max Loss \/ Unit<\/small>\r\n\r\n          <strong class=\"smos-max-loss-unit\">\r\n            \u20b90\r\n          <\/strong>\r\n\r\n        <\/div>\r\n\r\n      <\/div>\r\n\r\n\r\n      <!-- PAYOFF GRAPH -->\r\n\r\n      <div class=\"smos-panel\">\r\n\r\n        <h3>Expiry Payoff Chart<\/h3>\r\n\r\n        <div class=\"smos-chart-wrap\">\r\n\r\n          <canvas class=\"smos-chart\"><\/canvas>\r\n\r\n        <\/div>\r\n\r\n      <\/div>\r\n\r\n\r\n      <!-- PAYOFF TABLE -->\r\n\r\n      <div class=\"smos-panel\">\r\n\r\n        <h3>Expiry Profit \/ Loss Table<\/h3>\r\n\r\n        <div class=\"smos-table-scroll\">\r\n\r\n          <table class=\"smos-payoff-table\">\r\n\r\n            <thead>\r\n\r\n              <tr>\r\n\r\n                <th>Underlying Price<\/th>\r\n                <th>P&amp;L \/ Unit<\/th>\r\n                <th>Total P&amp;L<\/th>\r\n                <th>Status<\/th>\r\n\r\n              <\/tr>\r\n\r\n            <\/thead>\r\n\r\n            <tbody class=\"smos-payoff-body\"><\/tbody>\r\n\r\n          <\/table>\r\n\r\n        <\/div>\r\n\r\n      <\/div>\r\n\r\n\r\n      <!-- STRATEGY INTERPRETATION -->\r\n\r\n      <div class=\"smos-interpretation\">\r\n\r\n        <h3>Strategy Interpretation<\/h3>\r\n\r\n        <p class=\"smos-interpretation-text\"><\/p>\r\n\r\n      <\/div>\r\n\r\n\r\n      <!-- DISCLAIMER -->\r\n\r\n      <div class=\"smos-disclaimer\">\r\n\r\n        <strong>Risk Disclaimer:<\/strong>\r\n\r\n        This calculator is for educational and informational purposes only.\r\n        It does not constitute investment advice or a recommendation to buy\r\n        or sell any financial instrument. The payoff calculation represents\r\n        theoretical expiry P&amp;L based on the inputs provided. It does not\r\n        account for implied volatility changes, time decay before expiry,\r\n        brokerage, taxes, slippage, liquidity or execution costs.\r\n\r\n      <\/div>\r\n\r\n\r\n    <\/div>\r\n\r\n  <\/div>\r\n\r\n\r\n  <div class=\"smos-footer\">\r\n\r\n    StockMaster Universe \u2022 F&amp;O Trading Tools\r\n\r\n  <\/div>\r\n\r\n<\/div>\r\n\r\n\r\n<style>\r\n\r\n.smos-tool {\r\n  max-width: 1100px;\r\n  margin: 30px auto;\r\n  background: #ffffff;\r\n  border: 1px solid #e5e7eb;\r\n  border-radius: 18px;\r\n  overflow: hidden;\r\n  box-shadow: 0 8px 28px rgba(0,0,0,.07);\r\n  font-family: Arial, Helvetica, sans-serif;\r\n  color: #1f2937;\r\n}\r\n\r\n.smos-tool *,\r\n.smos-tool *:before,\r\n.smos-tool *:after {\r\n  box-sizing: border-box;\r\n}\r\n\r\n\r\n.smos-header {\r\n  background: #5b21b6;\r\n  color: #ffffff;\r\n  text-align: center;\r\n  padding: 30px 24px;\r\n}\r\n\r\n\r\n.smos-badge {\r\n  display: inline-block;\r\n  padding: 5px 10px;\r\n  border: 1px solid rgba(255,255,255,.35);\r\n  border-radius: 30px;\r\n  color: #f3e8ff;\r\n  font-size: 10px;\r\n  letter-spacing: 1px;\r\n  margin-bottom: 10px;\r\n}\r\n\r\n\r\n.smos-header h2 {\r\n  margin: 0 0 8px;\r\n  color: #ffffff;\r\n  font-size: 28px;\r\n  line-height: 1.3;\r\n}\r\n\r\n\r\n.smos-header p {\r\n  max-width: 760px;\r\n  margin: auto;\r\n  color: #ede9fe;\r\n  font-size: 15px;\r\n  line-height: 1.6;\r\n}\r\n\r\n\r\n.smos-body {\r\n  padding: 26px;\r\n}\r\n\r\n\r\n.smos-section-title {\r\n  display: flex;\r\n  align-items: center;\r\n  gap: 9px;\r\n  margin-bottom: 18px;\r\n  color: #111827;\r\n  font-size: 18px;\r\n  font-weight: 700;\r\n}\r\n\r\n\r\n.smos-section-title span {\r\n  width: 27px;\r\n  height: 27px;\r\n  display: inline-flex;\r\n  align-items: center;\r\n  justify-content: center;\r\n  border-radius: 50%;\r\n  background: #5b21b6;\r\n  color: #ffffff;\r\n  font-size: 13px;\r\n}\r\n\r\n\r\n.smos-space {\r\n  margin-top: 25px;\r\n}\r\n\r\n\r\n.smos-grid {\r\n  display: grid;\r\n  grid-template-columns: repeat(4,1fr);\r\n  gap: 14px;\r\n}\r\n\r\n\r\n.smos-field label {\r\n  display: block;\r\n  margin-bottom: 7px;\r\n  color: #374151;\r\n  font-size: 13px;\r\n  font-weight: 700;\r\n}\r\n\r\n\r\n.smos-field input,\r\n.smos-field select,\r\n.smos-leg-table input,\r\n.smos-leg-table select {\r\n  width: 100%;\r\n  padding: 11px 10px;\r\n  border: 1px solid #d1d5db;\r\n  border-radius: 8px;\r\n  background: #ffffff;\r\n  color: #111827;\r\n  font-size: 14px;\r\n  outline: none;\r\n}\r\n\r\n\r\n.smos-field input:focus,\r\n.smos-field select:focus,\r\n.smos-leg-table input:focus,\r\n.smos-leg-table select:focus {\r\n  border-color: #7c3aed;\r\n  box-shadow: 0 0 0 3px rgba(124,58,237,.10);\r\n}\r\n\r\n\r\n.smos-leg-table-wrap {\r\n  width: 100%;\r\n  overflow-x: auto;\r\n}\r\n\r\n\r\n.smos-leg-table {\r\n  width: 100%;\r\n  min-width: 760px;\r\n  border-collapse: collapse;\r\n}\r\n\r\n\r\n.smos-leg-table th {\r\n  padding: 11px 8px;\r\n  background: #f5f3ff;\r\n  color: #4c1d95;\r\n  text-align: left;\r\n  font-size: 11px;\r\n  white-space: nowrap;\r\n}\r\n\r\n\r\n.smos-leg-table td {\r\n  padding: 8px;\r\n  border-bottom: 1px solid #e5e7eb;\r\n}\r\n\r\n\r\n.smos-leg-table td:first-child {\r\n  width: 40px;\r\n  text-align: center;\r\n}\r\n\r\n\r\n.smos-remove {\r\n  width: 34px;\r\n  height: 34px;\r\n  border: 1px solid #e5e7eb;\r\n  border-radius: 7px;\r\n  background: #ffffff;\r\n  color: #991b1b;\r\n  font-size: 20px;\r\n  line-height: 1;\r\n  cursor: pointer;\r\n}\r\n\r\n\r\n.smos-remove:hover {\r\n  background: #fef2f2;\r\n}\r\n\r\n\r\n.smos-remove:disabled {\r\n  opacity: .35;\r\n  cursor: not-allowed;\r\n}\r\n\r\n\r\n.smos-buttons {\r\n  display: flex;\r\n  gap: 10px;\r\n  margin-top: 14px;\r\n}\r\n\r\n\r\n.smos-add,\r\n.smos-clear {\r\n  padding: 10px 15px;\r\n  border: 1px solid #d1d5db;\r\n  border-radius: 8px;\r\n  background: #ffffff;\r\n  color: #4c1d95;\r\n  font-weight: 700;\r\n  cursor: pointer;\r\n}\r\n\r\n\r\n.smos-add:hover,\r\n.smos-clear:hover {\r\n  background: #f5f3ff;\r\n}\r\n\r\n\r\n.smos-build {\r\n  width: 100%;\r\n  margin-top: 20px;\r\n  padding: 15px;\r\n  border: 0;\r\n  border-radius: 10px;\r\n  background: #5b21b6;\r\n  color: #ffffff;\r\n  font-size: 16px;\r\n  font-weight: 700;\r\n  cursor: pointer;\r\n}\r\n\r\n\r\n.smos-build:hover {\r\n  background: #4c1d95;\r\n}\r\n\r\n\r\n.smos-error {\r\n  display: none;\r\n  margin-top: 15px;\r\n  padding: 12px 14px;\r\n  border: 1px solid #fecaca;\r\n  border-radius: 8px;\r\n  background: #fef2f2;\r\n  color: #991b1b;\r\n  font-size: 13px;\r\n  line-height: 1.5;\r\n}\r\n\r\n\r\n.smos-results {\r\n  display: none;\r\n  margin-top: 30px;\r\n}\r\n\r\n\r\n.smos-strategy-box {\r\n  display: flex;\r\n  justify-content: space-between;\r\n  gap: 20px;\r\n  padding: 18px;\r\n  border: 1px solid #ddd6fe;\r\n  border-radius: 12px;\r\n  background: #f5f3ff;\r\n}\r\n\r\n\r\n.smos-strategy-box small {\r\n  display: block;\r\n  margin-bottom: 5px;\r\n  color: #6b7280;\r\n  font-size: 11px;\r\n}\r\n\r\n\r\n.smos-strategy-box strong {\r\n  color: #4c1d95;\r\n  font-size: 18px;\r\n}\r\n\r\n\r\n.smos-result-title {\r\n  margin-top: 25px;\r\n}\r\n\r\n\r\n.smos-result-grid {\r\n  display: grid;\r\n  grid-template-columns: repeat(4,1fr);\r\n  gap: 12px;\r\n}\r\n\r\n\r\n.smos-card {\r\n  padding: 17px 10px;\r\n  border: 1px solid #e5e7eb;\r\n  border-radius: 11px;\r\n  background: #fafafa;\r\n  text-align: center;\r\n}\r\n\r\n\r\n.smos-card small {\r\n  display: block;\r\n  margin-bottom: 7px;\r\n  color: #6b7280;\r\n  font-size: 11px;\r\n  font-weight: 600;\r\n}\r\n\r\n\r\n.smos-card strong {\r\n  display: block;\r\n  color: #4c1d95;\r\n  font-size: 17px;\r\n}\r\n\r\n\r\n.smos-profit-card {\r\n  background: #f0fdf4;\r\n  border-color: #bbf7d0;\r\n}\r\n\r\n\r\n.smos-profit-card strong {\r\n  color: #15803d;\r\n}\r\n\r\n\r\n.smos-loss-card {\r\n  background: #fef2f2;\r\n  border-color: #fecaca;\r\n}\r\n\r\n\r\n.smos-loss-card strong {\r\n  color: #b91c1c;\r\n}\r\n\r\n\r\n.smos-panel {\r\n  margin-top: 22px;\r\n  padding: 20px;\r\n  border: 1px solid #e5e7eb;\r\n  border-radius: 12px;\r\n}\r\n\r\n\r\n.smos-panel h3,\r\n.smos-interpretation h3 {\r\n  margin: 0 0 15px;\r\n  color: #111827;\r\n  font-size: 17px;\r\n}\r\n\r\n\r\n.smos-chart-wrap {\r\n  position: relative;\r\n  width: 100%;\r\n  height: 390px;\r\n}\r\n\r\n\r\n.smos-chart {\r\n  display: block;\r\n  width: 100%;\r\n  height: 100%;\r\n}\r\n\r\n\r\n.smos-table-scroll {\r\n  width: 100%;\r\n  max-height: 420px;\r\n  overflow: auto;\r\n}\r\n\r\n\r\n.smos-payoff-table {\r\n  width: 100%;\r\n  border-collapse: collapse;\r\n}\r\n\r\n\r\n.smos-payoff-table th {\r\n  position: sticky;\r\n  top: 0;\r\n  z-index: 2;\r\n  padding: 11px;\r\n  background: #5b21b6;\r\n  color: #ffffff;\r\n  font-size: 12px;\r\n  text-align: left;\r\n}\r\n\r\n\r\n.smos-payoff-table td {\r\n  padding: 10px 11px;\r\n  border-bottom: 1px solid #e5e7eb;\r\n  font-size: 12px;\r\n}\r\n\r\n\r\n.smos-payoff-table tr:nth-child(even) {\r\n  background: #fafafa;\r\n}\r\n\r\n\r\n.smos-positive {\r\n  color: #15803d;\r\n  font-weight: 700;\r\n}\r\n\r\n\r\n.smos-negative {\r\n  color: #b91c1c;\r\n  font-weight: 700;\r\n}\r\n\r\n\r\n.smos-interpretation {\r\n  margin-top: 22px;\r\n  padding: 18px;\r\n  border: 1px solid #ddd6fe;\r\n  border-radius: 11px;\r\n  background: #f5f3ff;\r\n}\r\n\r\n\r\n.smos-interpretation p {\r\n  margin: 0;\r\n  color: #4b5563;\r\n  font-size: 13px;\r\n  line-height: 1.7;\r\n}\r\n\r\n\r\n.smos-disclaimer {\r\n  margin-top: 22px;\r\n  padding: 15px;\r\n  border: 1px solid #fde68a;\r\n  border-radius: 9px;\r\n  background: #fffbeb;\r\n  color: #78350f;\r\n  font-size: 11px;\r\n  line-height: 1.6;\r\n}\r\n\r\n\r\n.smos-footer {\r\n  padding: 14px;\r\n  border-top: 1px solid #e5e7eb;\r\n  background: #f9fafb;\r\n  color: #6b7280;\r\n  text-align: center;\r\n  font-size: 11px;\r\n}\r\n\r\n\r\n@media(max-width:850px) {\r\n\r\n  .smos-grid {\r\n    grid-template-columns: repeat(2,1fr);\r\n  }\r\n\r\n  .smos-result-grid {\r\n    grid-template-columns: repeat(2,1fr);\r\n  }\r\n\r\n}\r\n\r\n\r\n@media(max-width:650px) {\r\n\r\n  .smos-tool {\r\n    margin: 15px 5px;\r\n    border-radius: 13px;\r\n  }\r\n\r\n  .smos-header {\r\n    padding: 23px 16px;\r\n  }\r\n\r\n  .smos-header h2 {\r\n    font-size: 23px;\r\n  }\r\n\r\n  .smos-body {\r\n    padding: 17px;\r\n  }\r\n\r\n  .smos-grid {\r\n    grid-template-columns: 1fr;\r\n  }\r\n\r\n  .smos-result-grid {\r\n    grid-template-columns: repeat(2,1fr);\r\n  }\r\n\r\n  .smos-strategy-box {\r\n    flex-direction: column;\r\n  }\r\n\r\n  .smos-chart-wrap {\r\n    height: 300px;\r\n  }\r\n\r\n}\r\n\r\n\r\n@media(max-width:400px) {\r\n\r\n  .smos-result-grid {\r\n    grid-template-columns: 1fr;\r\n  }\r\n\r\n  .smos-buttons {\r\n    flex-direction: column;\r\n  }\r\n\r\n  .smos-header h2 {\r\n    font-size: 21px;\r\n  }\r\n\r\n}\r\n\r\n<\/style>\r\n\r\n\r\n<script>\r\n\r\n(function() {\r\n\r\n  function initSMOS() {\r\n\r\n    var tools =\r\n      document.querySelectorAll('.smos-tool');\r\n\r\n\r\n    tools.forEach(function(tool) {\r\n\r\n      if (tool.dataset.smosLoaded === '1') {\r\n        return;\r\n      }\r\n\r\n      tool.dataset.smosLoaded = '1';\r\n\r\n\r\n      var addButton =\r\n        tool.querySelector('.smos-add');\r\n\r\n\r\n      var clearButton =\r\n        tool.querySelector('.smos-clear');\r\n\r\n\r\n      var buildButton =\r\n        tool.querySelector('.smos-build');\r\n\r\n\r\n      var errorBox =\r\n        tool.querySelector('.smos-error');\r\n\r\n\r\n      var results =\r\n        tool.querySelector('.smos-results');\r\n\r\n\r\n      var legsContainer =\r\n        tool.querySelector('.smos-legs');\r\n\r\n\r\n      var maxLegs = 4;\r\n\r\n\r\n      function money(value) {\r\n\r\n        if (!isFinite(value)) {\r\n          return '\u20b90';\r\n        }\r\n\r\n        return '\u20b9' +\r\n          Number(value).toLocaleString('en-IN', {\r\n            maximumFractionDigits: 2\r\n          });\r\n\r\n      }\r\n\r\n\r\n      function number(value) {\r\n\r\n        if (!isFinite(value)) {\r\n          return '0';\r\n        }\r\n\r\n        return Number(value).toLocaleString('en-IN', {\r\n          maximumFractionDigits: 2\r\n        });\r\n\r\n      }\r\n\r\n\r\n      function getLegs() {\r\n\r\n        var rows =\r\n          tool.querySelectorAll('.smos-leg');\r\n\r\n\r\n        var legs = [];\r\n\r\n\r\n        rows.forEach(function(row) {\r\n\r\n          var action =\r\n            row.querySelector('.smos-action').value;\r\n\r\n\r\n          var type =\r\n            row.querySelector('.smos-type').value;\r\n\r\n\r\n          var strike =\r\n            parseFloat(\r\n              row.querySelector('.smos-strike').value\r\n            );\r\n\r\n\r\n          var premium =\r\n            parseFloat(\r\n              row.querySelector('.smos-premium').value\r\n            );\r\n\r\n\r\n          var qty =\r\n            parseFloat(\r\n              row.querySelector('.smos-qty').value\r\n            );\r\n\r\n\r\n          legs.push({\r\n            action: action,\r\n            type: type,\r\n            strike: strike,\r\n            premium: premium,\r\n            qty: qty\r\n          });\r\n\r\n        });\r\n\r\n\r\n        return legs;\r\n\r\n      }\r\n\r\n\r\n      function renumberLegs() {\r\n\r\n        var rows =\r\n          tool.querySelectorAll('.smos-leg');\r\n\r\n\r\n        rows.forEach(function(row, index) {\r\n\r\n          row.querySelector('td:first-child strong')\r\n            .textContent =\r\n            index + 1;\r\n\r\n\r\n          var remove =\r\n            row.querySelector('.smos-remove');\r\n\r\n\r\n          remove.disabled =\r\n            rows.length <= 1;\r\n\r\n        });\r\n\r\n      }\r\n\r\n\r\n      function createLeg(index) {\r\n\r\n        var row =\r\n          document.createElement('tr');\r\n\r\n\r\n        row.className =\r\n          'smos-leg';\r\n\r\n\r\n        row.innerHTML =\r\n\r\n          '<td data-label=\"Leg\">' +\r\n            '<strong>' + index + '<\/strong>' +\r\n          '<\/td>' +\r\n\r\n          '<td data-label=\"Action\">' +\r\n            '<select class=\"smos-action\">' +\r\n              '<option value=\"buy\">Buy<\/option>' +\r\n              '<option value=\"sell\">Sell<\/option>' +\r\n            '<\/select>' +\r\n          '<\/td>' +\r\n\r\n          '<td data-label=\"Type\">' +\r\n            '<select class=\"smos-type\">' +\r\n              '<option value=\"call\">Call<\/option>' +\r\n              '<option value=\"put\">Put<\/option>' +\r\n            '<\/select>' +\r\n          '<\/td>' +\r\n\r\n          '<td data-label=\"Strike\">' +\r\n            '<input type=\"number\" class=\"smos-strike\" ' +\r\n            'value=\"25000\" min=\"0\" step=\"0.01\">' +\r\n          '<\/td>' +\r\n\r\n          '<td data-label=\"Premium\">' +\r\n            '<input type=\"number\" class=\"smos-premium\" ' +\r\n            'value=\"100\" min=\"0\" step=\"0.01\">' +\r\n          '<\/td>' +\r\n\r\n          '<td data-label=\"Lots\">' +\r\n            '<input type=\"number\" class=\"smos-qty\" ' +\r\n            'value=\"1\" min=\"1\" step=\"1\">' +\r\n          '<\/td>' +\r\n\r\n          '<td>' +\r\n            '<button type=\"button\" class=\"smos-remove\">\u00d7<\/button>' +\r\n          '<\/td>';\r\n\r\n\r\n        return row;\r\n\r\n      }\r\n\r\n\r\n      addButton.addEventListener(\r\n        'click',\r\n        function() {\r\n\r\n          var count =\r\n            tool.querySelectorAll('.smos-leg').length;\r\n\r\n\r\n          if (count >= maxLegs) {\r\n\r\n            errorBox.textContent =\r\n              'You can build a strategy with a maximum of 4 option legs.';\r\n\r\n            errorBox.style.display =\r\n              'block';\r\n\r\n            return;\r\n\r\n          }\r\n\r\n\r\n          errorBox.style.display =\r\n            'none';\r\n\r\n\r\n          var row =\r\n            createLeg(count + 1);\r\n\r\n\r\n          legsContainer.appendChild(row);\r\n\r\n\r\n          renumberLegs();\r\n\r\n        }\r\n      );\r\n\r\n\r\n      legsContainer.addEventListener(\r\n        'click',\r\n        function(event) {\r\n\r\n          if (\r\n            event.target.classList.contains(\r\n              'smos-remove'\r\n            )\r\n          ) {\r\n\r\n            var rows =\r\n              tool.querySelectorAll('.smos-leg');\r\n\r\n\r\n            if (rows.length <= 1) {\r\n              return;\r\n            }\r\n\r\n\r\n            event.target\r\n              .closest('.smos-leg')\r\n              .remove();\r\n\r\n\r\n            renumberLegs();\r\n\r\n          }\r\n\r\n        }\r\n      );\r\n\r\n\r\n      clearButton.addEventListener(\r\n        'click',\r\n        function() {\r\n\r\n          legsContainer.innerHTML = '';\r\n\r\n          var row =\r\n            createLeg(1);\r\n\r\n          legsContainer.appendChild(row);\r\n\r\n          renumberLegs();\r\n\r\n          results.style.display =\r\n            'none';\r\n\r\n          errorBox.style.display =\r\n            'none';\r\n\r\n        }\r\n      );\r\n\r\n\r\n      \/*\r\n       * Payoff calculation\r\n       *\/\r\n\r\n      function payoffAt(price, legs, lotSize) {\r\n\r\n        var total = 0;\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          var intrinsic = 0;\r\n\r\n\r\n          if (leg.type === 'call') {\r\n\r\n            intrinsic =\r\n              Math.max(\r\n                0,\r\n                price - leg.strike\r\n              );\r\n\r\n          } else {\r\n\r\n            intrinsic =\r\n              Math.max(\r\n                0,\r\n                leg.strike - price\r\n              );\r\n\r\n          }\r\n\r\n\r\n          var payoffPerUnit;\r\n\r\n\r\n          if (leg.action === 'buy') {\r\n\r\n            payoffPerUnit =\r\n              intrinsic - leg.premium;\r\n\r\n          } else {\r\n\r\n            payoffPerUnit =\r\n              leg.premium - intrinsic;\r\n\r\n          }\r\n\r\n\r\n          total +=\r\n            payoffPerUnit *\r\n            leg.qty *\r\n            lotSize;\r\n\r\n        });\r\n\r\n\r\n        return total;\r\n\r\n      }\r\n\r\n\r\n      function payoffPerUnit(price, legs) {\r\n\r\n        var total = 0;\r\n\r\n        var totalUnits = 0;\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          var intrinsic = 0;\r\n\r\n\r\n          if (leg.type === 'call') {\r\n\r\n            intrinsic =\r\n              Math.max(\r\n                0,\r\n                price - leg.strike\r\n              );\r\n\r\n          } else {\r\n\r\n            intrinsic =\r\n              Math.max(\r\n                0,\r\n                leg.strike - price\r\n              );\r\n\r\n          }\r\n\r\n\r\n          var payoff;\r\n\r\n\r\n          if (leg.action === 'buy') {\r\n\r\n            payoff =\r\n              intrinsic - leg.premium;\r\n\r\n          } else {\r\n\r\n            payoff =\r\n              leg.premium - intrinsic;\r\n\r\n          }\r\n\r\n\r\n          total +=\r\n            payoff * leg.qty;\r\n\r\n\r\n          totalUnits +=\r\n            leg.qty;\r\n\r\n        });\r\n\r\n\r\n        return totalUnits > 0\r\n          ? total \/ totalUnits\r\n          : 0;\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Net premium\r\n       *\/\r\n\r\n      function netPremium(legs) {\r\n\r\n        var total = 0;\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          if (leg.action === 'buy') {\r\n\r\n            total -=\r\n              leg.premium *\r\n              leg.qty;\r\n\r\n          } else {\r\n\r\n            total +=\r\n              leg.premium *\r\n              leg.qty;\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        return total;\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Strategy profile\r\n       *\/\r\n\r\n      function getProfile(legs) {\r\n\r\n        var callLong = 0;\r\n        var callShort = 0;\r\n        var putLong = 0;\r\n        var putShort = 0;\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          if (\r\n            leg.type === 'call' &&\r\n            leg.action === 'buy'\r\n          ) {\r\n\r\n            callLong += leg.qty;\r\n\r\n          }\r\n\r\n\r\n          if (\r\n            leg.type === 'call' &&\r\n            leg.action === 'sell'\r\n          ) {\r\n\r\n            callShort += leg.qty;\r\n\r\n          }\r\n\r\n\r\n          if (\r\n            leg.type === 'put' &&\r\n            leg.action === 'buy'\r\n          ) {\r\n\r\n            putLong += leg.qty;\r\n\r\n          }\r\n\r\n\r\n          if (\r\n            leg.type === 'put' &&\r\n            leg.action === 'sell'\r\n          ) {\r\n\r\n            putShort += leg.qty;\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        var name =\r\n          'Custom Option Strategy';\r\n\r\n\r\n        var bias =\r\n          'Neutral';\r\n\r\n\r\n        if (\r\n          legs.length === 1 &&\r\n          callLong === 1\r\n        ) {\r\n\r\n          name =\r\n            'Long Call';\r\n\r\n          bias =\r\n            'Bullish';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 1 &&\r\n          putLong === 1\r\n        ) {\r\n\r\n          name =\r\n            'Long Put';\r\n\r\n          bias =\r\n            'Bearish';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 1 &&\r\n          callShort === 1\r\n        ) {\r\n\r\n          name =\r\n            'Short Call';\r\n\r\n          bias =\r\n            'Bearish \/ Neutral';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 1 &&\r\n          putShort === 1\r\n        ) {\r\n\r\n          name =\r\n            'Short Put';\r\n\r\n          bias =\r\n            'Bullish \/ Neutral';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 2 &&\r\n          callLong === 1 &&\r\n          callShort === 1\r\n        ) {\r\n\r\n          var calls =\r\n            legs\r\n              .filter(function(l) {\r\n                return l.type === 'call';\r\n              });\r\n\r\n\r\n          if (\r\n            calls[0].action !==\r\n            calls[1].action\r\n          ) {\r\n\r\n            name =\r\n              'Call Spread';\r\n\r\n\r\n            bias =\r\n              calls.some(function(l) {\r\n                return l.action === 'buy' &&\r\n                       l.strike <\r\n                       calls.find(function(x) {\r\n                         return x.action === 'sell';\r\n                       }).strike;\r\n              })\r\n              ? 'Bullish'\r\n              : 'Bearish';\r\n\r\n          }\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 2 &&\r\n          putLong === 1 &&\r\n          putShort === 1\r\n        ) {\r\n\r\n          var puts =\r\n            legs\r\n              .filter(function(l) {\r\n                return l.type === 'put';\r\n              });\r\n\r\n\r\n          name =\r\n            'Put Spread';\r\n\r\n\r\n          bias =\r\n            puts.some(function(l) {\r\n              return l.action === 'buy' &&\r\n                     l.strike >\r\n                     puts.find(function(x) {\r\n                       return x.action === 'sell';\r\n                     }).strike;\r\n            })\r\n            ? 'Bearish'\r\n            : 'Bullish';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 2 &&\r\n          callLong === 1 &&\r\n          putLong === 1\r\n        ) {\r\n\r\n          name =\r\n            'Long Strangle \/ Straddle';\r\n\r\n\r\n          bias =\r\n            'Volatility';\r\n\r\n        }\r\n\r\n\r\n        else if (\r\n          legs.length === 2 &&\r\n          callShort === 1 &&\r\n          putShort === 1\r\n        ) {\r\n\r\n          name =\r\n            'Short Strangle \/ Straddle';\r\n\r\n\r\n          bias =\r\n            'Neutral \/ Volatility';\r\n\r\n        }\r\n\r\n\r\n        return {\r\n          name: name,\r\n          bias: bias\r\n        };\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Calculate exact extrema\r\n       *\/\r\n\r\n      function calculateExtrema(legs, lotSize) {\r\n\r\n        var strikes = [];\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          if (\r\n            isFinite(leg.strike) &&\r\n            leg.strike >= 0\r\n          ) {\r\n\r\n            strikes.push(leg.strike);\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        strikes.sort(function(a,b) {\r\n          return a - b;\r\n        });\r\n\r\n\r\n        var unique = [];\r\n\r\n\r\n        strikes.forEach(function(value) {\r\n\r\n          if (\r\n            unique.length === 0 ||\r\n            unique[unique.length - 1] !== value\r\n          ) {\r\n\r\n            unique.push(value);\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        \/*\r\n         * Payoff at every strike\r\n         *\/\r\n\r\n        var points =\r\n          unique.map(function(strike) {\r\n\r\n            return {\r\n              price: strike,\r\n              payoff: payoffAt(\r\n                strike,\r\n                legs,\r\n                lotSize\r\n              )\r\n            };\r\n\r\n          });\r\n\r\n\r\n        \/*\r\n         * Net slopes at both tails.\r\n         *\r\n         * Call:\r\n         * long = +1 at high prices\r\n         * short = -1 at high prices\r\n         *\r\n         * Put:\r\n         * long = -1 at low prices\r\n         * short = +1 at low prices\r\n         *\/\r\n\r\n        var highSlope = 0;\r\n        var lowSlope = 0;\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          if (leg.type === 'call') {\r\n\r\n            highSlope +=\r\n              leg.action === 'buy'\r\n              ? leg.qty\r\n              : -leg.qty;\r\n\r\n          }\r\n\r\n\r\n          if (leg.type === 'put') {\r\n\r\n            lowSlope +=\r\n              leg.action === 'buy'\r\n              ? -leg.qty\r\n              : leg.qty;\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        var maxProfit =\r\n          -Infinity;\r\n\r\n\r\n        var maxLoss =\r\n          Infinity;\r\n\r\n\r\n        points.forEach(function(point) {\r\n\r\n          maxProfit =\r\n            Math.max(\r\n              maxProfit,\r\n              point.payoff\r\n            );\r\n\r\n\r\n          maxLoss =\r\n            Math.min(\r\n              maxLoss,\r\n              point.payoff\r\n            );\r\n\r\n        });\r\n\r\n\r\n        \/*\r\n         * Tail behaviour\r\n         *\/\r\n\r\n        if (highSlope > 0) {\r\n\r\n          maxProfit =\r\n            Infinity;\r\n\r\n        }\r\n\r\n\r\n        if (highSlope < 0) {\r\n\r\n          maxLoss =\r\n            -Infinity;\r\n\r\n        }\r\n\r\n\r\n        if (lowSlope < 0) {\r\n\r\n          maxProfit =\r\n            Infinity;\r\n\r\n        }\r\n\r\n\r\n        if (lowSlope > 0) {\r\n\r\n          maxLoss =\r\n            -Infinity;\r\n\r\n        }\r\n\r\n\r\n        return {\r\n          maxProfit: maxProfit,\r\n          maxLoss: maxLoss,\r\n          points: points\r\n        };\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Find breakevens\r\n       *\/\r\n\r\n      function findBreakevens(legs, lotSize, minPrice, maxPrice) {\r\n\r\n        var strikes = [];\r\n\r\n\r\n        legs.forEach(function(leg) {\r\n\r\n          strikes.push(leg.strike);\r\n\r\n        });\r\n\r\n\r\n        strikes.push(minPrice);\r\n        strikes.push(maxPrice);\r\n\r\n\r\n        strikes.sort(function(a,b) {\r\n          return a - b;\r\n        });\r\n\r\n\r\n        var unique = [];\r\n\r\n\r\n        strikes.forEach(function(value) {\r\n\r\n          if (\r\n            unique.length === 0 ||\r\n            Math.abs(\r\n              unique[unique.length - 1] -\r\n              value\r\n            ) > 0.000001\r\n          ) {\r\n\r\n            unique.push(value);\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        var roots = [];\r\n\r\n\r\n        function addRoot(root) {\r\n\r\n          if (\r\n            root < minPrice ||\r\n            root > maxPrice\r\n          ) {\r\n            return;\r\n          }\r\n\r\n\r\n          var exists =\r\n            roots.some(function(r) {\r\n\r\n              return Math.abs(r - root) <\r\n                Math.max(0.01, root * 0.000001);\r\n\r\n            });\r\n\r\n\r\n          if (!exists) {\r\n\r\n            roots.push(root);\r\n\r\n          }\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Check exact strike points\r\n         *\/\r\n\r\n        unique.forEach(function(price) {\r\n\r\n          var p =\r\n            payoffAt(\r\n              price,\r\n              legs,\r\n              lotSize\r\n            );\r\n\r\n\r\n          if (\r\n            Math.abs(p) <\r\n            0.000001\r\n          ) {\r\n\r\n            addRoot(price);\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        \/*\r\n         * Find roots between strikes\r\n         *\/\r\n\r\n        for (\r\n          var i = 0;\r\n          i < unique.length - 1;\r\n          i++\r\n        ) {\r\n\r\n          var a =\r\n            unique[i];\r\n\r\n          var b =\r\n            unique[i + 1];\r\n\r\n\r\n          if (b <= a) {\r\n            continue;\r\n          }\r\n\r\n\r\n          var pa =\r\n            payoffAt(\r\n              a,\r\n              legs,\r\n              lotSize\r\n            );\r\n\r\n\r\n          var pb =\r\n            payoffAt(\r\n              b,\r\n              legs,\r\n              lotSize\r\n            );\r\n\r\n\r\n          if (\r\n            pa === 0 ||\r\n            pb === 0\r\n          ) {\r\n            continue;\r\n          }\r\n\r\n\r\n          if (\r\n            (pa < 0 && pb > 0) ||\r\n            (pa > 0 && pb < 0)\r\n          ) {\r\n\r\n            var root =\r\n              a +\r\n              (\r\n                -pa *\r\n                (b - a) \/\r\n                (pb - pa)\r\n              );\r\n\r\n\r\n            addRoot(root);\r\n\r\n          }\r\n\r\n        }\r\n\r\n\r\n        roots.sort(function(a,b) {\r\n          return a - b;\r\n        });\r\n\r\n\r\n        return roots;\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Canvas chart\r\n       *\/\r\n\r\n      function drawChart(\r\n        prices,\r\n        profits,\r\n        strikes,\r\n        breakevens\r\n      ) {\r\n\r\n        var canvas =\r\n          tool.querySelector(\r\n            '.smos-chart'\r\n          );\r\n\r\n\r\n        var wrapper =\r\n          canvas.parentElement;\r\n\r\n\r\n        var width =\r\n          wrapper.clientWidth;\r\n\r\n\r\n        var height =\r\n          wrapper.clientHeight;\r\n\r\n\r\n        var ratio =\r\n          window.devicePixelRatio || 1;\r\n\r\n\r\n        canvas.width =\r\n          width * ratio;\r\n\r\n\r\n        canvas.height =\r\n          height * ratio;\r\n\r\n\r\n        canvas.style.width =\r\n          width + 'px';\r\n\r\n\r\n        canvas.style.height =\r\n          height + 'px';\r\n\r\n\r\n        var ctx =\r\n          canvas.getContext('2d');\r\n\r\n\r\n        ctx.scale(ratio, ratio);\r\n\r\n\r\n        var padding = {\r\n          left: 55,\r\n          right: 20,\r\n          top: 20,\r\n          bottom: 45\r\n        };\r\n\r\n\r\n        var chartWidth =\r\n          width -\r\n          padding.left -\r\n          padding.right;\r\n\r\n\r\n        var chartHeight =\r\n          height -\r\n          padding.top -\r\n          padding.bottom;\r\n\r\n\r\n        var minPrice =\r\n          Math.min.apply(\r\n            null,\r\n            prices\r\n          );\r\n\r\n\r\n        var maxPrice =\r\n          Math.max.apply(\r\n            null,\r\n            prices\r\n          );\r\n\r\n\r\n        var minProfit =\r\n          Math.min.apply(\r\n            null,\r\n            profits\r\n          );\r\n\r\n\r\n        var maxProfit =\r\n          Math.max.apply(\r\n            null,\r\n            profits\r\n          );\r\n\r\n\r\n        if (\r\n          minProfit === maxProfit\r\n        ) {\r\n\r\n          minProfit -= 100;\r\n          maxProfit += 100;\r\n\r\n        }\r\n\r\n\r\n        var margin =\r\n          Math.max(\r\n            100,\r\n            (maxProfit - minProfit) *\r\n            0.1\r\n          );\r\n\r\n\r\n        minProfit -= margin;\r\n        maxProfit += margin;\r\n\r\n\r\n        function x(price) {\r\n\r\n          return padding.left +\r\n            (\r\n              (price - minPrice) \/\r\n              (maxPrice - minPrice)\r\n            ) *\r\n            chartWidth;\r\n\r\n        }\r\n\r\n\r\n        function y(value) {\r\n\r\n          return padding.top +\r\n            (\r\n              (maxProfit - value) \/\r\n              (maxProfit - minProfit)\r\n            ) *\r\n            chartHeight;\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Background\r\n         *\/\r\n\r\n        ctx.clearRect(\r\n          0,\r\n          0,\r\n          width,\r\n          height\r\n        );\r\n\r\n\r\n        \/*\r\n         * Grid lines\r\n         *\/\r\n\r\n        ctx.strokeStyle =\r\n          '#e5e7eb';\r\n\r\n        ctx.lineWidth =\r\n          1;\r\n\r\n\r\n        for (\r\n          var g = 0;\r\n          g <= 5;\r\n          g++\r\n        ) {\r\n\r\n          var gy =\r\n            padding.top +\r\n            (chartHeight \/ 5) * g;\r\n\r\n\r\n          ctx.beginPath();\r\n\r\n          ctx.moveTo(\r\n            padding.left,\r\n            gy\r\n          );\r\n\r\n          ctx.lineTo(\r\n            width - padding.right,\r\n            gy\r\n          );\r\n\r\n          ctx.stroke();\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Zero line\r\n         *\/\r\n\r\n        if (\r\n          minProfit <= 0 &&\r\n          maxProfit >= 0\r\n        ) {\r\n\r\n          var zeroY =\r\n            y(0);\r\n\r\n\r\n          ctx.strokeStyle =\r\n            '#9ca3af';\r\n\r\n          ctx.lineWidth =\r\n            1.5;\r\n\r\n\r\n          ctx.beginPath();\r\n\r\n          ctx.moveTo(\r\n            padding.left,\r\n            zeroY\r\n          );\r\n\r\n          ctx.lineTo(\r\n            width - padding.right,\r\n            zeroY\r\n          );\r\n\r\n          ctx.stroke();\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Strike lines\r\n         *\/\r\n\r\n        ctx.strokeStyle =\r\n          '#ddd6fe';\r\n\r\n        ctx.setLineDash([4,4]);\r\n\r\n\r\n        strikes.forEach(function(strike) {\r\n\r\n          if (\r\n            strike >= minPrice &&\r\n            strike <= maxPrice\r\n          ) {\r\n\r\n            var sx =\r\n              x(strike);\r\n\r\n\r\n            ctx.beginPath();\r\n\r\n            ctx.moveTo(\r\n              sx,\r\n              padding.top\r\n            );\r\n\r\n            ctx.lineTo(\r\n              sx,\r\n              height - padding.bottom\r\n            );\r\n\r\n            ctx.stroke();\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        ctx.setLineDash([]);\r\n\r\n\r\n        \/*\r\n         * Payoff line\r\n         *\/\r\n\r\n        ctx.strokeStyle =\r\n          '#5b21b6';\r\n\r\n        ctx.lineWidth =\r\n          3;\r\n\r\n\r\n        ctx.beginPath();\r\n\r\n\r\n        prices.forEach(function(price, index) {\r\n\r\n          var px =\r\n            x(price);\r\n\r\n\r\n          var py =\r\n            y(profits[index]);\r\n\r\n\r\n          if (index === 0) {\r\n\r\n            ctx.moveTo(px,py);\r\n\r\n          } else {\r\n\r\n            ctx.lineTo(px,py);\r\n\r\n          }\r\n\r\n        });\r\n\r\n\r\n        ctx.stroke();\r\n\r\n\r\n        \/*\r\n         * Breakeven markers\r\n         *\/\r\n\r\n        breakevens.forEach(function(root) {\r\n\r\n          var bx =\r\n            x(root);\r\n\r\n\r\n          var by =\r\n            y(0);\r\n\r\n\r\n          ctx.fillStyle =\r\n            '#111827';\r\n\r\n\r\n          ctx.beginPath();\r\n\r\n          ctx.arc(\r\n            bx,\r\n            by,\r\n            5,\r\n            0,\r\n            Math.PI * 2\r\n          );\r\n\r\n          ctx.fill();\r\n\r\n        });\r\n\r\n\r\n        \/*\r\n         * X axis labels\r\n         *\/\r\n\r\n        ctx.fillStyle =\r\n          '#6b7280';\r\n\r\n        ctx.font =\r\n          '11px Arial';\r\n\r\n\r\n        ctx.textAlign =\r\n          'center';\r\n\r\n\r\n        for (\r\n          var t = 0;\r\n          t <= 4;\r\n          t++\r\n        ) {\r\n\r\n          var price =\r\n            minPrice +\r\n            (\r\n              (maxPrice - minPrice) \/\r\n              4\r\n            ) * t;\r\n\r\n\r\n          ctx.fillText(\r\n            money(price),\r\n            x(price),\r\n            height - 15\r\n          );\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Y labels\r\n         *\/\r\n\r\n        ctx.textAlign =\r\n          'right';\r\n\r\n\r\n        for (\r\n          var yp = 0;\r\n          yp <= 4;\r\n          yp++\r\n        ) {\r\n\r\n          var value =\r\n            maxProfit -\r\n            (\r\n              (maxProfit - minProfit) \/\r\n              4\r\n            ) * yp;\r\n\r\n\r\n          ctx.fillText(\r\n            money(value),\r\n            padding.left - 8,\r\n            y(value) + 4\r\n          );\r\n\r\n        }\r\n\r\n\r\n        \/*\r\n         * Axis labels\r\n         *\/\r\n\r\n        ctx.textAlign =\r\n          'center';\r\n\r\n        ctx.fillStyle =\r\n          '#374151';\r\n\r\n        ctx.font =\r\n          '12px Arial';\r\n\r\n\r\n        ctx.fillText(\r\n          'Underlying Price at Expiry',\r\n          width \/ 2,\r\n          height - 1\r\n        );\r\n\r\n\r\n        ctx.save();\r\n\r\n        ctx.translate(\r\n          13,\r\n          height \/ 2\r\n        );\r\n\r\n        ctx.rotate(-Math.PI \/ 2);\r\n\r\n        ctx.fillText(\r\n          'Profit \/ Loss',\r\n          0,\r\n          0\r\n        );\r\n\r\n        ctx.restore();\r\n\r\n      }\r\n\r\n\r\n      \/*\r\n       * Build strategy\r\n       *\/\r\n\r\n      buildButton.addEventListener(\r\n        'click',\r\n        function() {\r\n\r\n\r\n          errorBox.style.display =\r\n            'none';\r\n\r\n\r\n          var spot =\r\n            parseFloat(\r\n              tool.querySelector(\r\n                '.smos-spot'\r\n              ).value\r\n            );\r\n\r\n\r\n          var lotSize =\r\n            parseFloat(\r\n              tool.querySelector(\r\n                '.smos-lot'\r\n              ).value\r\n            );\r\n\r\n\r\n          var range =\r\n            parseFloat(\r\n              tool.querySelector(\r\n                '.smos-range'\r\n              ).value\r\n            );\r\n\r\n\r\n          var stepCount =\r\n            parseInt(\r\n              tool.querySelector(\r\n                '.smos-steps'\r\n              ).value,\r\n              10\r\n            );\r\n\r\n\r\n          if (\r\n            !isFinite(spot) ||\r\n            !isFinite(lotSize) ||\r\n            spot <= 0 ||\r\n            lotSize <= 0\r\n          ) {\r\n\r\n            errorBox.textContent =\r\n              'Please enter a valid underlying price and lot size.';\r\n\r\n            errorBox.style.display =\r\n              'block';\r\n\r\n            return;\r\n\r\n          }\r\n\r\n\r\n          var legs =\r\n            getLegs();\r\n\r\n\r\n          if (\r\n            legs.length === 0\r\n          ) {\r\n\r\n            errorBox.textContent =\r\n              'Please add at least one option leg.';\r\n\r\n            errorBox.style.display =\r\n              'block';\r\n\r\n            return;\r\n\r\n          }\r\n\r\n\r\n          var valid =\r\n            true;\r\n\r\n\r\n          legs.forEach(function(leg) {\r\n\r\n            if (\r\n              !isFinite(leg.strike) ||\r\n              !isFinite(leg.premium) ||\r\n              !isFinite(leg.qty) ||\r\n\r\n              leg.strike <= 0 ||\r\n              leg.premium < 0 ||\r\n              leg.qty <= 0\r\n            ) {\r\n\r\n              valid = false;\r\n\r\n            }\r\n\r\n          });\r\n\r\n\r\n          if (!valid) {\r\n\r\n            errorBox.textContent =\r\n              'Please enter valid Strike, Premium and Lot values for every leg.';\r\n\r\n            errorBox.style.display =\r\n              'block';\r\n\r\n            return;\r\n\r\n          }\r\n\r\n\r\n          \/*\r\n           * Range\r\n           *\/\r\n\r\n          var minPrice =\r\n            spot *\r\n            (1 - range \/ 100);\r\n\r\n\r\n          var maxPrice =\r\n            spot *\r\n            (1 + range \/ 100);\r\n\r\n\r\n          \/*\r\n           * Generate prices\r\n           *\/\r\n\r\n          var prices = [];\r\n\r\n\r\n          for (\r\n            var i = 0;\r\n            i < stepCount;\r\n            i++\r\n          ) {\r\n\r\n            prices.push(\r\n              minPrice +\r\n              (\r\n                (maxPrice - minPrice) \/\r\n                (stepCount - 1)\r\n              ) * i\r\n            );\r\n\r\n          }\r\n\r\n\r\n          \/*\r\n           * Payoffs\r\n           *\/\r\n\r\n          var profits =\r\n            prices.map(function(price) {\r\n\r\n              return payoffAt(\r\n                price,\r\n                legs,\r\n                lotSize\r\n              );\r\n\r\n            });\r\n\r\n\r\n          \/*\r\n           * Exact extrema\r\n           *\/\r\n\r\n          var extrema =\r\n            calculateExtrema(\r\n              legs,\r\n              lotSize\r\n            );\r\n\r\n\r\n          \/*\r\n           * Breakevens\r\n           *\/\r\n\r\n          var breakevens =\r\n            findBreakevens(\r\n              legs,\r\n              lotSize,\r\n              minPrice,\r\n              maxPrice\r\n            );\r\n\r\n\r\n          \/*\r\n           * Profile\r\n           *\/\r\n\r\n          var profile =\r\n            getProfile(legs);\r\n\r\n\r\n          \/*\r\n           * Net premium\r\n           *\r\n           * Positive = credit\r\n           * Negative = debit\r\n           *\/\r\n\r\n          var premiumPerStrategy =\r\n            netPremium(legs);\r\n\r\n\r\n          var totalLots =\r\n            legs.reduce(function(sum, leg) {\r\n\r\n              return sum + leg.qty;\r\n\r\n            }, 0);\r\n\r\n\r\n          var totalContracts =\r\n            totalLots *\r\n            lotSize;\r\n\r\n\r\n          \/*\r\n           * Unit values\r\n           *\/\r\n\r\n          var maxProfitUnit =\r\n            extrema.maxProfit === Infinity\r\n            ? Infinity\r\n            : extrema.maxProfit \/\r\n              lotSize;\r\n\r\n\r\n          var maxLossUnit =\r\n            extrema.maxLoss === -Infinity\r\n            ? -Infinity\r\n            : extrema.maxLoss \/\r\n              lotSize;\r\n\r\n\r\n          \/*\r\n           * Display profile\r\n           *\/\r\n\r\n          tool.querySelector(\r\n            '.smos-strategy-name'\r\n          ).textContent =\r\n            profile.name;\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-bias'\r\n          ).textContent =\r\n            profile.bias;\r\n\r\n\r\n          \/*\r\n           * Net premium\r\n           *\/\r\n\r\n          var premiumLabel =\r\n            premiumPerStrategy >= 0\r\n            ? 'Credit '\r\n            : 'Debit ';\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-net-premium'\r\n          ).textContent =\r\n            premiumLabel +\r\n            money(\r\n              Math.abs(\r\n                premiumPerStrategy *\r\n                lotSize\r\n              )\r\n            );\r\n\r\n\r\n          \/*\r\n           * Max profit\r\n           *\/\r\n\r\n          tool.querySelector(\r\n            '.smos-max-profit'\r\n          ).textContent =\r\n            extrema.maxProfit === Infinity\r\n            ? 'Unlimited'\r\n            : money(extrema.maxProfit);\r\n\r\n\r\n          \/*\r\n           * Max loss\r\n           *\/\r\n\r\n          tool.querySelector(\r\n            '.smos-max-loss'\r\n          ).textContent =\r\n            extrema.maxLoss === -Infinity\r\n            ? 'Unlimited'\r\n            : money(\r\n              Math.abs(\r\n                extrema.maxLoss\r\n              )\r\n            );\r\n\r\n\r\n          \/*\r\n           * Breakevens\r\n           *\/\r\n\r\n          if (\r\n            breakevens.length === 0\r\n          ) {\r\n\r\n            tool.querySelector(\r\n              '.smos-breakeven'\r\n            ).textContent =\r\n              'None in range';\r\n\r\n          } else {\r\n\r\n            tool.querySelector(\r\n              '.smos-breakeven'\r\n            ).textContent =\r\n              breakevens\r\n                .map(function(value) {\r\n                  return money(value);\r\n                })\r\n                .join(' \u2022 ');\r\n\r\n          }\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-total-lots'\r\n          ).textContent =\r\n            number(totalLots);\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-contracts'\r\n          ).textContent =\r\n            number(totalContracts);\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-max-profit-unit'\r\n          ).textContent =\r\n            maxProfitUnit === Infinity\r\n            ? 'Unlimited'\r\n            : money(maxProfitUnit);\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-max-loss-unit'\r\n          ).textContent =\r\n            maxLossUnit === -Infinity\r\n            ? 'Unlimited'\r\n            : money(\r\n              Math.abs(\r\n                maxLossUnit\r\n              )\r\n            );\r\n\r\n\r\n          \/*\r\n           * Chart\r\n           *\/\r\n\r\n          drawChart(\r\n            prices,\r\n            profits,\r\n            legs.map(function(leg) {\r\n              return leg.strike;\r\n            }),\r\n            breakevens\r\n          );\r\n\r\n\r\n          \/*\r\n           * Payoff table\r\n           *\/\r\n\r\n          var tableBody =\r\n            tool.querySelector(\r\n              '.smos-payoff-body'\r\n            );\r\n\r\n\r\n          tableBody.innerHTML =\r\n            '';\r\n\r\n\r\n          prices.forEach(function(price, index) {\r\n\r\n            \/*\r\n             * Show all points when\r\n             * number of steps is reasonable.\r\n             *\/\r\n\r\n            var row =\r\n              document.createElement('tr');\r\n\r\n\r\n            var pnl =\r\n              profits[index];\r\n\r\n\r\n            var status =\r\n              pnl > 0.005\r\n              ? 'Profit'\r\n              : pnl < -0.005\r\n              ? 'Loss'\r\n              : 'Breakeven';\r\n\r\n\r\n            var pnlClass =\r\n              pnl > 0.005\r\n              ? 'smos-positive'\r\n              : pnl < -0.005\r\n              ? 'smos-negative'\r\n              : '';\r\n\r\n\r\n            row.innerHTML =\r\n\r\n              '<td>' +\r\n                money(price) +\r\n              '<\/td>' +\r\n\r\n              '<td class=\"' +\r\n                pnlClass +\r\n              '\">' +\r\n                money(\r\n                  payoffPerUnit(\r\n                    price,\r\n                    legs\r\n                  )\r\n                ) +\r\n              '<\/td>' +\r\n\r\n              '<td class=\"' +\r\n                pnlClass +\r\n              '\">' +\r\n                money(pnl) +\r\n              '<\/td>' +\r\n\r\n              '<td class=\"' +\r\n                pnlClass +\r\n              '\">' +\r\n                status +\r\n              '<\/td>';\r\n\r\n\r\n            tableBody.appendChild(row);\r\n\r\n          });\r\n\r\n\r\n          \/*\r\n           * Interpretation\r\n           *\/\r\n\r\n          var interpretation =\r\n            'This strategy is currently classified as ' +\r\n            profile.name +\r\n            ' with a ' +\r\n            profile.bias +\r\n            ' profile. ';\r\n\r\n\r\n          if (\r\n            extrema.maxProfit === Infinity\r\n          ) {\r\n\r\n            interpretation +=\r\n              'The theoretical maximum profit is unlimited. ';\r\n\r\n          } else {\r\n\r\n            interpretation +=\r\n              'The theoretical maximum profit at expiry is ' +\r\n              money(extrema.maxProfit) +\r\n              '. ';\r\n\r\n          }\r\n\r\n\r\n          if (\r\n            extrema.maxLoss === -Infinity\r\n          ) {\r\n\r\n            interpretation +=\r\n              'The theoretical maximum loss is unlimited. ';\r\n\r\n          } else {\r\n\r\n            interpretation +=\r\n              'The theoretical maximum loss at expiry is ' +\r\n              money(\r\n                Math.abs(\r\n                  extrema.maxLoss\r\n                )\r\n              ) +\r\n              '. ';\r\n\r\n          }\r\n\r\n\r\n          if (\r\n            breakevens.length\r\n          ) {\r\n\r\n            interpretation +=\r\n              'The calculated breakeven level(s) within the selected ' +\r\n              'price range are ' +\r\n              breakevens\r\n                .map(function(value) {\r\n                  return money(value);\r\n                })\r\n                .join(', ') +\r\n              '. ';\r\n\r\n          } else {\r\n\r\n            interpretation +=\r\n              'No breakeven level was found within the selected chart range. ';\r\n\r\n          }\r\n\r\n\r\n          interpretation +=\r\n            'The payoff shown is based on expiry and does not represent ' +\r\n            'the strategy value before expiry.';\r\n\r\n\r\n          tool.querySelector(\r\n            '.smos-interpretation-text'\r\n          ).textContent =\r\n            interpretation;\r\n\r\n\r\n          results.style.display =\r\n            'block';\r\n\r\n\r\n          \/*\r\n           * Resize chart\r\n           *\/\r\n\r\n          setTimeout(function() {\r\n\r\n            drawChart(\r\n              prices,\r\n              profits,\r\n              legs.map(function(leg) {\r\n                return leg.strike;\r\n              }),\r\n              breakevens\r\n            );\r\n\r\n          }, 100);\r\n\r\n\r\n          \/*\r\n           * Mobile scroll\r\n           *\/\r\n\r\n          if (\r\n            window.innerWidth < 650\r\n          ) {\r\n\r\n            setTimeout(function() {\r\n\r\n              results.scrollIntoView({\r\n                behavior: 'smooth',\r\n                block: 'start'\r\n              });\r\n\r\n            }, 120);\r\n\r\n          }\r\n\r\n        }\r\n      );\r\n\r\n\r\n      \/*\r\n       * Redraw chart on resize\r\n       *\/\r\n\r\n      window.addEventListener(\r\n        'resize',\r\n        function() {\r\n\r\n          \/*\r\n           * Chart is rebuilt only if\r\n           * results are currently visible.\r\n           *\/\r\n\r\n          if (\r\n            results.style.display === 'block'\r\n          ) {\r\n\r\n            buildButton.click();\r\n\r\n          }\r\n\r\n        }\r\n      );\r\n\r\n\r\n      renumberLegs();\r\n\r\n    });\r\n\r\n  }\r\n\r\n\r\n  if (\r\n    document.readyState === 'loading'\r\n  ) {\r\n\r\n    document.addEventListener(\r\n      'DOMContentLoaded',\r\n      initSMOS\r\n    );\r\n\r\n  } else {\r\n\r\n    initSMOS();\r\n\r\n  }\r\n\r\n})();\r\n\r\n<\/script>\n<p style=\"text-align: justify;\">The <strong><a href=\"https:\/\/www.stockmaster.in\/universe\/\">StockMaster Universe<\/a> F&amp;O Option Strategy Builder<\/strong> is a practical tool for futures and options traders who want to understand how different option positions can work together before entering a trade. Instead of analysing every option leg separately, traders can build a multi-leg strategy and view its theoretical profit and loss at expiry.<\/p>\n<p style=\"text-align: justify;\">The tool supports up to <strong>four option legs<\/strong>, allowing traders to create simple as well as more advanced option strategies.<\/p>\n<p><strong>What Is an Option Strategy Builder?<\/strong><\/p>\n<p>An option strategy builder allows traders to combine different Call and Put positions to create a complete trading strategy.<\/p>\n<p>Each leg can be configured as:<\/p>\n<ul>\n<li>Buy Call<\/li>\n<li>Sell Call<\/li>\n<li>Buy Put<\/li>\n<li>Sell Put<\/li>\n<li>Strike price<\/li>\n<li>Option premium<\/li>\n<li>Number of lots<\/li>\n<\/ul>\n<p>The calculator then combines these positions and estimates the overall expiry payoff.<\/p>\n<p>This makes it easier to understand how a strategy may behave when the underlying asset moves higher or lower.<\/p>\n<p><strong>Build Multiple Option Strategies<\/strong><\/p>\n<p>The F&amp;O Option Strategy Builder can be used to analyse many common strategies, including:<\/p>\n<ul>\n<li>Long Call<\/li>\n<li>Long Put<\/li>\n<li>Short Call<\/li>\n<li>Short Put<\/li>\n<li>Bull Call Spread<\/li>\n<li>Bear Call Spread<\/li>\n<li>Bull Put Spread<\/li>\n<li>Bear Put Spread<\/li>\n<li>Long Straddle<\/li>\n<li>Short Straddle<\/li>\n<li>Long Strangle<\/li>\n<li>Short Strangle<\/li>\n<li>Iron Condor<\/li>\n<li>Custom multi-leg strategies<\/li>\n<\/ul>\n<p>The ability to add multiple legs makes the tool useful for both beginner and experienced options traders.<\/p>\n<h3>How to Use the Option Strategy Builder<\/h3>\n<p>Start by entering the current or reference price of the underlying asset and the applicable option lot size.<\/p>\n<p>Next, add your option legs.<\/p>\n<p>For every leg, select:<\/p>\n<p><strong>Buy or Sell \u2192 Call or Put \u2192 Strike Price \u2192 Premium \u2192 Lots<\/strong><\/p>\n<p>After entering the strategy, click <strong>Build Strategy &amp; Calculate Payoff<\/strong>.<\/p>\n<p>The calculator analyses all the legs together and displays the theoretical expiry results.<\/p>\n<p><strong>What Does the Calculator Show?<\/strong><\/p>\n<p>The StockMaster Universe Option Strategy Builder provides several useful results:<\/p>\n<ul>\n<li>Net premium<\/li>\n<li>Maximum profit<\/li>\n<li>Maximum loss<\/li>\n<li>Breakeven levels<\/li>\n<li>Total lots<\/li>\n<li>Total contracts<\/li>\n<li>Maximum profit per unit<\/li>\n<li>Maximum loss per unit<\/li>\n<li>Expiry payoff chart<\/li>\n<li>Expiry profit\/loss table<\/li>\n<li>Strategy profile<\/li>\n<li>Bullish, bearish or neutral bias<\/li>\n<\/ul>\n<p>This allows traders to quickly understand the overall structure of a strategy.<\/p>\n<p><strong>Example: Bull Call Spread<\/strong><\/p>\n<p>Suppose a trader expects the market to rise but wants to limit the cost of the trade.<\/p>\n<p>They could create a Bull Call Spread by:<\/p>\n<p><strong>Buying a 25,000 Call for \u20b9250<\/strong><\/p>\n<p>and<\/p>\n<p><strong>Selling a 25,500 Call for \u20b9100<\/strong><\/p>\n<p>With a lot size of 75, the net premium paid is:<\/p>\n<p><strong>\u20b9150 \u00d7 75 = \u20b911,250<\/strong><\/p>\n<p>The maximum loss is therefore approximately <strong>\u20b911,250<\/strong>, while the maximum profit is approximately <strong>\u20b926,250<\/strong>, before considering brokerage, taxes and other trading costs.<\/p>\n<p>The breakeven level would be approximately <strong>\u20b925,150<\/strong>.<\/p>\n<p>The payoff chart helps traders visualise how the strategy behaves at different expiry prices.<\/p>\n<h3>Why Use an Option Strategy Builder?<\/h3>\n<p>Options can become difficult to analyse when multiple contracts are combined.<\/p>\n<p>A strategy may have limited risk, unlimited risk, multiple breakeven points or a specific profit zone.<\/p>\n<p>The builder makes these relationships easier to understand by presenting the combined position in one place.<\/p>\n<p>It can be particularly useful when comparing strategies before entering a trade.<\/p>\n<h4>Understanding the Payoff Chart<\/h4>\n<p>The payoff chart displays the theoretical profit or loss at different underlying prices at expiry.<\/p>\n<p>Prices above the breakeven level may produce a profit, while prices below it may produce a loss, depending on the strategy.<\/p>\n<p>For strategies such as Iron Condors and Straddles, the chart can make the potential profit zone and risk zone much easier to identify.<\/p>\n<h4>Important Limitation<\/h4>\n<p style=\"text-align: justify;\">This calculator primarily shows <strong>theoretical expiry payoff<\/strong>.<\/p>\n<p style=\"text-align: justify;\">It does not attempt to predict the actual option premium before expiry based on implied volatility, time decay, interest rates or changes in volatility.<\/p>\n<p style=\"text-align: justify;\">Actual trading results can also differ because of brokerage, taxes, slippage, liquidity and execution prices.<\/p>\n<h4>Key Takeaway<\/h4>\n<p><strong>Before entering a multi-leg options trade, understand the complete payoff\u2014not just individual option premiums.<\/strong><\/p>\n<p>The StockMaster Universe F&amp;O Option Strategy Builder helps traders visualise potential expiry outcomes, identify breakeven levels and understand the theoretical risk and reward of their chosen option strategy.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The StockMaster Universe F&amp;O Option Strategy Builder is a practical tool for futures and options traders who want to understand [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"elementor_theme","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"default","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"set","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[62],"tags":[],"class_list":["post-490","post","type-post","status-publish","format-standard","hentry","category-fo-trading-tools"],"rttpg_featured_image_url":null,"rttpg_author":{"display_name":"StockMaster Universe","author_link":"https:\/\/www.stockmaster.in\/universe\/author\/unistockadmin\/"},"rttpg_comment":0,"rttpg_category":"<a href=\"https:\/\/www.stockmaster.in\/universe\/category\/tools\/fo-trading-tools\/\" rel=\"category tag\">F&amp;O Trading Tools<\/a>","rttpg_excerpt":"The StockMaster Universe F&amp;O Option Strategy Builder is a practical tool for futures and options traders who want to understand [&hellip;]","_links":{"self":[{"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/posts\/490","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/comments?post=490"}],"version-history":[{"count":0,"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/posts\/490\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/media?parent=490"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/categories?post=490"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.stockmaster.in\/universe\/wp-json\/wp\/v2\/tags?post=490"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}