1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1984],{39109:(e,n,s)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/classes/FeatureUnion",function(){return s(6152)}])},6152:(e,n,s)=>{"use strict";s.r(n),s.d(n,{default:()=>c,useTOC:()=>l});var r=s(86106),t=s(30138),d=s(32126),i=s(69912);function l(e){return[{value:"Constructors",id:"constructors",depth:2},{value:"new FeatureUnion()",id:"new-featureunion",depth:3},{value:"Properties",id:"properties",depth:2},{value:"Accessors",id:"accessors",depth:2},{value:"named_transformers",id:"named_transformers",depth:3},{value:"py",id:"py",depth:3},{value:"Methods",id:"methods",depth:2},{value:"dispose()",id:"dispose",depth:3},{value:"fit()",id:"fit",depth:3},{value:"fit_transform()",id:"fit_transform",depth:3},{value:"get_feature_names_out()",id:"get_feature_names_out",depth:3},{value:"get_metadata_routing()",id:"get_metadata_routing",depth:3},{value:"init()",id:"init",depth:3},{value:"set_output()",id:"set_output",depth:3},{value:"transform()",id:"transform",depth:3}]}let c=(0,t.e)(function(e){let{toc:n=l(e)}=e,s={a:"a",blockquote:"blockquote",code:"code",h1:"h1",h2:"h2",h3:"h3",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(s.h1,{children:"Class: FeatureUnion"}),"\n",(0,r.jsx)(s.p,{children:"Concatenates results of multiple transformer objects."}),"\n",(0,r.jsx)(s.p,{children:"This estimator applies a list of transformer objects in parallel to the input data, then concatenates the results. This is useful to combine several feature extraction mechanisms into a single transformer."}),"\n",(0,r.jsx)(s.p,{children:"Parameters of the transformers may be set using its name and the parameter name separated by a â__â. A transformer may be replaced entirely by setting the parameter with its name to another transformer, removed by setting to âdropâ or disabled by setting to âpassthroughâ (features are passed without transformation)."}),"\n",(0,r.jsxs)(s.p,{children:["Read more in the ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/../compose.html#feature-union",children:"User Guide"}),"."]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.FeatureUnion.html",children:"Python Reference"})}),"\n",(0,r.jsx)(s.h2,{id:n[0].id,children:n[0].value}),"\n",(0,r.jsx)(s.h3,{id:n[1].id,children:n[1].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"new FeatureUnion"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"?): ",(0,r.jsx)(s.a,{href:"FeatureUnion",children:(0,r.jsx)(s.code,{children:"FeatureUnion"})})]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.n_jobs"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"number"})}),(0,r.jsxs)(s.td,{children:["Number of jobs to run in parallel. ",(0,r.jsx)(s.code,{children:"undefined"})," means 1 unless in a ",(0,r.jsx)(s.a,{href:"https://joblib.readthedocs.io/en/latest/generated/joblib.parallel_backend.html#joblib.parallel_backend",title:"(in joblib v1.5.dev0)",children:(0,r.jsx)(s.code,{children:"joblib.parallel_backend"})})," context. ",(0,r.jsx)(s.code,{children:"\\-1"})," means using all processors. See ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/../../glossary.html#term-n_jobs",children:"Glossary"})," for more details."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.transformer_list"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsx)(s.td,{children:"List of transformer objects to be applied to the data. The first half of each tuple is the name of the transformer. The transformer can be âdropâ for it to be ignored or can be âpassthroughâ for features to be passed unchanged."})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.transformer_weights"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsxs)(s.td,{children:["Multiplicative weights for features per transformer. Keys are transformer names, values the weights. Raises ValueError if key not present in ",(0,r.jsx)(s.code,{children:"transformer_list"}),"."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.verbose"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"boolean"})}),(0,r.jsxs)(s.td,{children:["If ",(0,r.jsx)(s.code,{children:"true"}),", the time elapsed while fitting each transformer will be printed as it is completed."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.verbose_feature_names_out"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"boolean"})}),(0,r.jsxs)(s.td,{children:["If ",(0,r.jsx)(s.code,{children:"true"}),", ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/#sklearn.pipeline.FeatureUnion.get_feature_names_out",title:"sklearn.pipeline.FeatureUnion.get_feature_names_out",children:(0,r.jsx)(s.code,{children:"get_feature_names_out"})})," will prefix all feature names with the name of the transformer that generated that feature. If ",(0,r.jsx)(s.code,{children:"false"}),", ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/#sklearn.pipeline.FeatureUnion.get_feature_names_out",title:"sklearn.pipeline.FeatureUnion.get_feature_names_out",children:(0,r.jsx)(s.code,{children:"get_feature_names_out"})})," will not prefix any feature names and will error if feature names are not unique."]})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.a,{href:"FeatureUnion",children:(0,r.jsx)(s.code,{children:"FeatureUnion"})})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L27",children:"generated/pipeline/FeatureUnion.ts:27"})]}),"\n",(0,r.jsx)(s.h2,{id:n[2].id,children:n[2].value}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Property"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Default value"}),(0,r.jsx)(s.th,{children:"Defined in"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"_isDisposed"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"boolean"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"false"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L25",children:"generated/pipeline/FeatureUnion.ts:25"})})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"_isInitialized"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"boolean"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"false"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L24",children:"generated/pipeline/FeatureUnion.ts:24"})})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"_py"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"PythonBridge"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"undefined"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L23",children:"generated/pipeline/FeatureUnion.ts:23"})})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"id"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"string"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"undefined"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L20",children:"generated/pipeline/FeatureUnion.ts:20"})})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"undefined"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L21",children:"generated/pipeline/FeatureUnion.ts:21"})})]})]})]}),"\n",(0,r.jsx)(s.h2,{id:n[3].id,children:n[3].value}),"\n",(0,r.jsx)(s.h3,{id:n[4].id,children:n[4].value}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Get Signature"})}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"get"})," ",(0,r.jsx)(s.strong,{children:"named_transformers"}),"(): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Dictionary-like object, with the following attributes. Read-only attribute to access any transformer parameter by user given name. Ke
1ys are transformer names and values are transformer parameters."}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L355",children:"generated/pipeline/FeatureUnion.ts:355"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[5].id,children:n[5].value}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Get Signature"})}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"get"})," ",(0,r.jsx)(s.strong,{children:"py"}),"(): ",(0,r.jsx)(s.code,{children:"PythonBridge"})]}),"\n"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"PythonBridge"})]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Set Signature"})}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"set"})," ",(0,r.jsx)(s.strong,{children:"py"}),"(",(0,r.jsx)(s.code,{children:"pythonBridge"}),"): ",(0,r.jsx)(s.code,{children:"void"})]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"})]})}),(0,r.jsx)(s.tbody,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"pythonBridge"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"PythonBridge"})})]})})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"void"})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L61",children:"generated/pipeline/FeatureUnion.ts:61"})]}),"\n",(0,r.jsx)(s.h2,{id:n[6].id,children:n[6].value}),"\n",(0,r.jsx)(s.h3,{id:n[7].id,children:n[7].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"dispose"}),"(): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"void"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Disposes of the underlying Python resources."}),"\n",(0,r.jsxs)(s.p,{children:["Once ",(0,r.jsx)(s.code,{children:"dispose()"})," is called, the instance is no longer usable."]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"void"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L113",children:"generated/pipeline/FeatureUnion.ts:113"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[8].id,children:n[8].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"fit"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Fit all transformers using X."}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.fit_params"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsxs)(s.td,{children:["If ",(0,r.jsx)(s.code,{children:"enable_metadata_routing=False"})," (default): Parameters directly passed to the ",(0,r.jsx)(s.code,{children:"fit"})," methods of the sub-transformers."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.X"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"ArrayLike"})}),(0,r.jsx)(s.td,{children:"Input data, used to fit transformers."})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.y"}),"?"]}),(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"ArrayLike"}),"[]"]}),(0,r.jsx)(s.td,{children:"Targets for supervised learning."})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L130",children:"generated/pipeline/FeatureUnion.ts:130"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[9].id,children:n[9].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"fit_transform"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"ArrayLike"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Fit all transformers, transform the data and concatenate results."}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.params"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsxs)(s.td,{children:["If ",(0,r.jsx)(s.code,{children:"enable_metadata_routing=False"})," (default): Parameters directly passed to the ",(0,r.jsx)(s.code,{children:"fit"})," methods of the sub-transformers."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.X"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"ArrayLike"})}),(0,r.jsx)(s.td,{children:"Input data to be transformed."})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.y"}),"?"]}),(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"ArrayLike"}),"[]"]}),(0,r.jsx)(s.td,{children:"Targets for supervised learning."})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"ArrayLike"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L172",children:"generated/pipeline/FeatureUnion.ts:172"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[10].id,children:n[10].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"get_feature_names_out"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Get output feature names for transformation."}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.input_features"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsx)(s.td,{children:"Input features."})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L214",children:"generated/pipeline/FeatureUnion.ts:214"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[11].id,children:n[11].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"get_metadata_routing"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Get metadata routing of this object."}),"\n",(0,r.jsxs)(s.p,{children:["Please check ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/../../metadata_routing.html#metadata-routing",children:"User Guide"})," on how the routing mechanism works."]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.routing"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsxs)(s.td,{children:["A ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.MetadataRouter.html#sklearn.utils.metadata_routing.MetadataRouter",title:"sklearn.utils.metadata_routing.MetadataRouter",children:(0,r.jsx)(s.code,{children:"MetadataRouter"})})," encapsulating routing information."]})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L250",children:"generated/pipeline/FeatureUnion.ts:250"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[12].id,children:n[12].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"init"}),"(",(0,r.jsx)(s.code,{children:"py"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"void"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Initializes the underlying Python resources."}),"\n",(0,r.jsxs)(s.p,{children:["This instance is not usable until the ",(0,r.jsx)(s.code,{children:"Promise"})," returned by ",(0,r.jsx)(s.code,{children:"init()"})," resolves."]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"})]})}),(0,r.jsx)(s.tbody,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"py"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"PythonBridge"})})]})})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"void"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L74",children:"generated/pipeline/FeatureUnion.ts:74"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[13].id,children:n[13].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"set_output"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n"]}),"\n",(0,r.jsxs)(s.p,{children:["Set the output container when ",(0,r.jsx)(s.code,{children:'"transform"'})," and ",(0,r.jsx)(s.code,{children:'"fit_transform"'})," are called."]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.code,{children:"set_output"})," will set the output of all estimators in ",(0,r.jsx)(s.code,{children:"transformer_list"}),"."]}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.transform"}),"?"]}),(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:'"default"'})," | ",(0,r.jsx)(s.code,{children:'"pandas"'})," | ",(0,r.jsx)(s.code,{children:'"polars"'})]}),(0,r.jsxs)(s.td,{children:["Configure output of ",(0,r.jsx)(s.code,{children:"transform"})," and ",(0,r.jsx)(s.code,{children:"fit_transform"}),"."]})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L286",children:"generated/pipeline/FeatureUnion.ts:286"})]}),"\n",(0,r.jsx)(s.hr,{}),"\n",(0,r.jsx)(s.h3,{id:n[14].id,children:n[14].value}),"\n",(0,r.jsxs)(s.blockquote,{children:["\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"transform"}),"(",(0,r.jsx)(s.code,{children:"opts"}),"): ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"ArrayLike"}),">"]}),"\n"]}),"\n",(0,r.jsx)(s.p,{children:"Transform X separately by each transformer, concatenate results."}),"\n",(0,r.jsx)(s.p,{children:(0,r.jsx)(s.strong,{children:"Parameters"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(s.table,{children:[(0,r.jsx)(s.thead,{children:(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.th,{children:"Parameter"}),(0,r.jsx)(s.th,{children:"Type"}),(0,r.jsx)(s.th,{children:"Description"})]})}),(0,r.jsxs)(s.tbody,{children:[(0,r.jsxs)(s.tr,{children:[(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"opts"})}),(0,r.jsx)(s.td,{children:(0,r
1.jsx)(s.code,{children:"object"})}),(0,r.jsx)(s.td,{children:"-"})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.params"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"any"})}),(0,r.jsxs)(s.td,{children:["Parameters routed to the ",(0,r.jsx)(s.code,{children:"transform"})," method of the sub-transformers via the metadata routing API. See ",(0,r.jsx)(s.a,{href:"https://scikit-learn.org/stable/modules/generated/../../metadata_routing.html#metadata-routing",children:"Metadata Routing User Guide"})," for more details."]})]}),(0,r.jsxs)(s.tr,{children:[(0,r.jsxs)(s.td,{children:[(0,r.jsx)(s.code,{children:"opts.X"}),"?"]}),(0,r.jsx)(s.td,{children:(0,r.jsx)(s.code,{children:"ArrayLike"})}),(0,r.jsx)(s.td,{children:"Input data to be transformed."})]})]})]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Returns"})," ",(0,r.jsx)(s.code,{children:"Promise"}),"<",(0,r.jsx)(s.code,{children:"ArrayLike"}),">"]}),"\n",(0,r.jsxs)(s.p,{children:[(0,r.jsx)(s.strong,{children:"Defined in"})," ",(0,r.jsx)(s.a,{href:"https://github.com/transitive-bullshit/scikit-learn-ts/blob/bab9a6d8b9738b16b8b9ba0b3f7cea1495d968d8/packages/sklearn/src/generated/pipeline/FeatureUnion.ts#L318",children:"generated/pipeline/FeatureUnion.ts:318"})]})]})},"/docs/classes/FeatureUnion",{filePath:"pages/docs/classes/FeatureUnion.md",timestamp:1732212889e3,pageMap:d.O,frontMatter:{},title:"Class: FeatureUnion"},"undefined"==typeof RemoteContent?l:RemoteContent.useTOC)}},e=>{var n=n=>e(e.s=n);e.O(0,[138,2126,636,6593,8792],()=>n(39109)),_N_E=e.O()}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.