Non-sequential composition of pure functions
- To: mathgroup at smc.vnet.net
- Subject: [mg127785] Non-sequential composition of pure functions
- From: Earl Mitchell <earl.j.mitchell at gmail.com>
- Date: Wed, 22 Aug 2012 02:27:20 -0400 (EDT)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
- Delivered-to: l-mathgroup@wolfram.com
- Delivered-to: mathgroup-newout@smc.vnet.net
- Delivered-to: mathgroup-newsend@smc.vnet.net
Hi All, I have a list of pure functions (If[Conditional[#[[1]]],Action]& statements) and I want to compose them into one large pure function If[FirstConditional[#[[1]]]&&SecondConditional[#[[6]]]&&ThirdConditional[#[[foo]]],Action]&. They are to be applied to a list of values, and the conditionals checked for multiple columns for a given element of a list. I'm having problems joining these things together - to the point that I've considered converting them all to strings and doing the tedious (hackie) string manipulations to get the final function in the right form. Any recommendations on how to do this? I found Composition[] but it nests the functions - and I want to combine them. Thanks! Mitch
- Follow-Ups:
- Re: Non-sequential composition of pure functions
- From: Earl Mitchell <earl.j.mitchell@gmail.com>
- Re: Non-sequential composition of pure functions
- From: Earl Mitchell <earl.j.mitchell@gmail.com>
- Re: Non-sequential composition of pure functions
- From: Sseziwa Mukasa <mukasa@gmail.com>
- Re: Non-sequential composition of pure functions