{"record":{"id":"415f082d676c44ae","repo":"plotly/plotly.js","slug":"attempted-to-group-the-bins-of-trace-traceout-ind","errorCode":null,"errorMessage":"Attempted to group the bins of trace <traceOut.index> set on a type:<axType> axis with bins on type:<binOpts.axType> axis.","messagePattern":"Attempted to group the bins of trace <traceOut\\.index> set on a type:<axType> axis with bins on type:<binOpts\\.axType> axis\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/traces/histogram/cross_trace_defaults.js","lineNumber":64,"sourceCode":"        // N.B. group traces that don't have a bingroup with themselves\n        var fallbackGroupName = traceOut.uid + '__' + binDir;\n        if(!groupName) groupName = fallbackGroupName;\n\n        var axType = getAxisType(traceOut, binDir);\n        var calendar = traceOut[binDir + 'calendar'] || '';\n        var binOpts = allBinOpts[groupName];\n        var needsNewItem = true;\n\n        if(binOpts) {\n            if(axType === binOpts.axType && calendar === binOpts.calendar) {\n                needsNewItem = false;\n                binOpts.traces.push(traceOut);\n                binOpts.dirs.push(binDir);\n            } else {\n                groupName = fallbackGroupName;\n\n                if(axType !== binOpts.axType) {\n                    Lib.warn([\n                        'Attempted to group the bins of trace', traceOut.index,\n                        'set on a', 'type:' + axType, 'axis',\n                        'with bins on', 'type:' + binOpts.axType, 'axis.'\n                    ].join(' '));\n                }\n                if(calendar !== binOpts.calendar) {\n                    // prohibit bingroup for traces using different calendar,\n                    // there's probably a way to make this work, but skip for now\n                    Lib.warn([\n                        'Attempted to group the bins of trace', traceOut.index,\n                        'set with a', calendar, 'calendar',\n                        'with bins',\n                        (binOpts.calendar ? 'on a ' + binOpts.calendar + ' calendar' : 'w/o a set calendar')\n                    ].join(' '));\n                }\n            }\n        }\n","sourceCodeStart":46,"sourceCodeEnd":82,"githubUrl":"https://github.com/plotly/plotly.js/blob/1d090e0b5ffb8d0fdf6e0e4ff51d3f3cf67f1314/src/traces/histogram/cross_trace_defaults.js#L46-L82","documentation":"Warning from fillBinOpts, the cross-trace binning harmonizer for histogram-like traces. Traces sharing a bingroup must bin on the same kind of axis; the code keys bin options by group and records the axis type (linear/log/date/category) of the first trace. When a later trace's axis type differs from the group's stored axType, the traces cannot share bin size/offset settings, so the trace is split onto a fallback group of its own and this warning explains the split.","triggerScenarios":"Thrown at src/traces/histogram/cross_trace_defaults.js:64 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Put traces meant to share bins on axes of the same type (e.g. all linear or all log).","Remove the bingroup setting if the traces were not meant to be binned together.","Check for accidental yaxis/xaxis type overrides ('log', 'date') on one trace of the group.","Align axis type via layout (e.g. xaxis.type) before plotting the grouped histograms."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"1d090e0b5ffb8d0fdf6e0e4ff51d3f3cf67f1314","analyzedAt":"2026-09-02T22:03:39.906Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-10T02:17:09.455Z"}