{"record":{"id":"2f1a549a182e63b1","repo":"OpenBB-finance/OpenBB","slug":"please-provide-data-with-only-one-symbol-and-colum","errorCode":null,"errorMessage":"Please provide data with only one symbol and columns for OHLC.","messagePattern":"Please provide data with only one symbol and columns for OHLC\\.","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"openbb_platform/extensions/technical/openbb_technical/technical_views.py","lineNumber":71,"sourceCode":"    def technical_aroon(**kwargs) -> tuple[\"OpenBBFigure\", dict[str, Any]]:\n        \"\"\"Technical Aroon Chart.\"\"\"\n        # pylint: disable=import-outside-toplevel\n        from openbb_charting.core.plotly_ta.ta_class import PlotlyTA\n        from openbb_core.app.utils import basemodel_to_df\n        from pandas import DataFrame\n\n        if \"data\" in kwargs and isinstance(kwargs[\"data\"], DataFrame):\n            data = kwargs[\"data\"]\n        else:\n            data = basemodel_to_df(\n                kwargs[\"obbject_item\"], index=kwargs.get(\"index\", \"date\")\n            )\n\n        if \"date\" in data.columns:\n            data = data.set_index(\"date\")\n\n        if \"symbol\" in data.columns and len(data.symbol.unique()) > 1:\n            raise ValueError(\n                \"Please provide data with only one symbol and columns for OHLC.\"\n            )\n\n        symbol = kwargs.get(\"symbol\", \"\")\n\n        volume = kwargs.get(\"volume\") is True\n        title = f\"Aroon Indicator & Oscillator {symbol}\"\n\n        length = kwargs.get(\"length\", 25)\n        scalar = kwargs.get(\"scalar\", 100)\n        symbol = kwargs.get(\"symbol\", \"\")\n\n        ta = PlotlyTA()\n        fig = ta.plot(  # type: ignore\n            data,\n            dict(aroon=dict(length=length, scalar=scalar)),\n            title,\n            False,","sourceCodeStart":53,"sourceCodeEnd":89,"githubUrl":"https://github.com/OpenBB-finance/OpenBB/blob/3e071fcc2cd9f891cac6040ae60296dba76dab46/openbb_platform/extensions/technical/openbb_technical/technical_views.py#L53-L89","documentation":"Thrown by the Aroon charting view in the OpenBB technical extension when the OHLC data handed to the chart contains more than one unique value in the 'symbol' column. The technical indicator plotting backend (PlotlyTA) can only render indicators for a single instrument at a time, so the view rejects multi-symbol frames up front. The data comes either from kwargs['data'] (a DataFrame) or by converting the attached OBBject results to a DataFrame.","triggerScenarios":"Calling obbject.charting() (or chart/technical/aroon route) on results of a multi-symbol query, e.g. obb.equity.price.historical(symbol='AAPL,MSFT') then charting it; or passing a DataFrame with a 'symbol' column containing 2+ distinct symbols via the data kwarg after 'date' is set as index.","commonSituations":"Developer fetches historical prices for a watchlist/basket in one OBB call and then calls .charting(); provider returns data for multiple symbols merged into one frame; user supplies their own multi-ticker DataFrame to the Aroon view.","solutions":["Filter the DataFrame to a single symbol before charting: data = data[data['symbol'] == 'AAPL']","Fetch data for one symbol only: obb.equity.price.historical(symbol='AAPL')","Loop over symbols and call the chart function once per symbol slice"],"exampleFix":"# before\nres = obb.equity.price.historical(symbol='AAPL,MSFT')\nres.charting()\n\n# after\nres = obb.equity.price.historical(symbol='AAPL')\nres.charting()","handlingStrategy":"validation","validationCode":"if 'symbol' in df.columns and df['symbol'].nunique() > 1:\n    raise ValueError('chart one symbol at a time')\ndf = df[df['symbol'] == target_symbol] if 'symbol' in df.columns else df","typeGuard":"def is_single_symbol(df: pd.DataFrame) -> bool:\n    return 'symbol' not in df.columns or df['symbol'].nunique() == 1","tryCatchPattern":"try:\n    res.charting()\nexcept ValueError as e:\n    if 'only one symbol' in str(e):\n        for sym, g in df.groupby('symbol'):\n            chart_one(g)","preventionTips":["Fetch one ticker per charting call","Standardize on a helper that slices frames to a single symbol before chart views","Keep the symbol column until after the slice, then drop it"],"tags":["openbb","charting","technical-analysis","data-validation"],"backgroundTag":null,"analyzedSha":"3e071fcc2cd9f891cac6040ae60296dba76dab46","analyzedAt":"2026-08-14T23:40:48.960Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}