Files
OpenBB/assets/js/08212a07.00a0cbcb.js
github-actions[bot] 8169ee5420 deploy: c0d0989728
2024-06-24 09:37:45 +00:00

1 line
4.0 KiB
JavaScript

"use strict";(self.webpackChunkdocs=self.webpackChunkdocs||[]).push([[72852],{85952:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>l,contentTitle:()=>c,default:()=>u,frontMatter:()=>o,metadata:()=>d,toc:()=>a});var r=n(74848),s=n(28453),i=n(94331);const o={title:"weights",description:"This page provides the function to return the sector weightings allocation of any ETF using the OpenBB's yfinance model. It includes a link to the source code on GitHub.",keywords:["ETF","sector weightings allocation","yfinance model"]},c=void 0,d={id:"sdk/reference/etf/weights",title:"weights",description:"This page provides the function to return the sector weightings allocation of any ETF using the OpenBB's yfinance model. It includes a link to the source code on GitHub.",source:"@site/content/sdk/reference/etf/weights.md",sourceDirName:"sdk/reference/etf",slug:"/sdk/reference/etf/weights",permalink:"/sdk/reference/etf/weights",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenBB-finance/OpenBBTerminal/edit/main/website/content/sdk/reference/etf/weights.md",tags:[],version:"current",lastUpdatedBy:"montezdesousa",lastUpdatedAt:1719221197e3,frontMatter:{title:"weights",description:"This page provides the function to return the sector weightings allocation of any ETF using the OpenBB's yfinance model. It includes a link to the source code on GitHub.",keywords:["ETF","sector weightings allocation","yfinance model"]},sidebar:"tutorialSidebar",previous:{title:"symbols",permalink:"/sdk/reference/etf/symbols"},next:{title:"atr",permalink:"/sdk/reference/forecast/atr"}},l={},a=[{value:"Parameters",id:"parameters",level:2},{value:"Returns",id:"returns",level:2}];function h(e){const t={a:"a",code:"code",h2:"h2",hr:"hr",p:"p",pre:"pre",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(i.A,{title:"etf.weights - Reference | OpenBB SDK Docs"}),"\n",(0,r.jsx)(t.p,{children:"Return sector weightings allocation of ETF. [Source: Yahoo Finance]"}),"\n",(0,r.jsxs)(t.p,{children:["Source Code: [",(0,r.jsx)(t.a,{href:"https://github.com/OpenBB-finance/OpenBBTerminal/tree/main/openbb_terminal/etf/yfinance_model.py#L15",children:"link"}),"]"]}),"\n",(0,r.jsx)(t.pre,{children:(0,r.jsx)(t.code,{className:"language-python",children:"openbb.etf.weights(name: str)\n"})}),"\n",(0,r.jsx)(t.hr,{}),"\n",(0,r.jsx)(t.h2,{id:"parameters",children:"Parameters"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"}),(0,r.jsx)(t.th,{children:"Default"}),(0,r.jsx)(t.th,{children:"Optional"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"name"}),(0,r.jsx)(t.td,{children:"str"}),(0,r.jsx)(t.td,{children:"ETF name"}),(0,r.jsx)(t.td,{children:"None"}),(0,r.jsx)(t.td,{children:"False"})]})})]}),"\n",(0,r.jsx)(t.hr,{}),"\n",(0,r.jsx)(t.h2,{id:"returns",children:"Returns"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"Dict[str, Any]"}),(0,r.jsx)(t.td,{children:"Dictionary with sector weightings allocation"})]})})]}),"\n",(0,r.jsx)(t.hr,{})]})}function u(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},94331:(e,t,n)=>{n.d(t,{A:()=>i});n(96540);var r=n(5260),s=n(74848);function i(e){let{title:t}=e;return(0,s.jsx)(r.A,{children:(0,s.jsx)("title",{children:t})})}},28453:(e,t,n)=>{n.d(t,{R:()=>o,x:()=>c});var r=n(96540);const s={},i=r.createContext(s);function o(e){const t=r.useContext(i);return r.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:o(e.components),r.createElement(i.Provider,{value:t},e.children)}}}]);