[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Reply to: [list | sender only]
Re: [ddlm-group] Adding one more built-in function to dREL
- To: "Bollinger, John C" <John.Bollinger@stjude.org>
- Subject: Re: [ddlm-group] Adding one more built-in function to dREL
- From: James H <jamesrhester@gmail.com>
- Date: Thu, 12 May 2022 00:10:47 +1000
- Cc: Group finalising DDLm and associated dictionaries <ddlm-group@iucr.org>
- In-Reply-To: <CH2PR04MB6950F2BA5361E839AFD03CBDE0C89@CH2PR04MB6950.namprd04.prod.outlook.com>
- References: <CAM+dB2dH0zxLKrfD_r5BBBFhv3-xzssVGHDxp1HXJDb7eFz_EA@mail.gmail.com><CH2PR04MB6950F2BA5361E839AFD03CBDE0C89@CH2PR04MB6950.namprd04.prod.outlook.com>
"Indexof" sounds good to me. On Wed, 11 May 2022 at 23:33, Bollinger, John C<John.Bollinger@stjude.org> wrote:>> Dear James and Group,>> Such a function seems reasonable to me, but a more common spelling among functions with similar behavior would be "indexof" (JavaScript, Java, C#, Kotlin) or even plain "index" (Python, C, Fortran). The only common "indexin"s I find are in Julia and in Qt's QRegExp class -- after those, "indexof"s and "index in"s dominate my Google results for "indexin". Thus, I suggest using "indexof".>>> Best,>> John>>> -----Original Message-----> From: ddlm-group <ddlm-group-bounces@iucr.org> On Behalf Of James H> Sent: Tuesday, May 10, 2022 9:57 PM> To: ddlm-group <ddlm-group@iucr.org>> Subject: [ddlm-group] Adding one more built-in function to dREL>> Caution: External Sender. Do not open unless you know the content is safe.>>> Dear DDLm + dREL experts,>> Just a note that I would like to expand the list of dREL built-in functions to include the following function:>> indexin(list, value): return the first position of 'value' in 'list', returning -1 if not found. Positions count from 0 (in keeping with other built-in functions).>> I've found this can significantly improve the efficiency of "category methods", where whole columns of values can be assembled and sometimes the location of particular values in a list needs to be found.>> Let me know if you have any objections.>> thanks,> James.> --> T +61 (02) 9717 9907> F +61 (02) 9717 3145> M +61 (04) 0249 4148> _______________________________________________> ddlm-group mailing list> ddlm-group@iucr.org> https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmailman.iucr.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Fddlm-group&data=05%7C01%7CJohn.Bollinger%40stjude.org%7C538a9e2b41804070a02208da32f9f661%7C22340fa892264871b677d3b3e377af72%7C0%7C0%7C637878346818872894%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=0vEWSIycL1GA5PdD0rOt7GXAj95B1oQ4Bem%2Bj0YyPHI%3D&reserved=0>> ________________________________>> Email Disclaimer: www.stjude.org/emaildisclaimer> Consultation Disclaimer: www.stjude.org/consultationdisclaimer -- T +61 (02) 9717 9907F +61 (02) 9717 3145M +61 (04) 0249 4148_______________________________________________ddlm-group mailing listddlm-group@iucr.orghttp://mailman.iucr.org/cgi-bin/mailman/listinfo/ddlm-group
Reply to: [list | sender only]
- References:
- [ddlm-group] Adding one more built-in function to dREL (James H)
- Re: [ddlm-group] Adding one more built-in function to dREL (Bollinger, John C)
- Prev by Date: Re: [ddlm-group] Adding one more built-in function to dREL
- Next by Date: [ddlm-group] Minor change to DateTime DDLm type
- Prev by thread: Re: [ddlm-group] Adding one more built-in function to dREL
- Next by thread: [ddlm-group] Multi block principles
- Index(es):