Fork me on GitHub
#clojure-europe
<
2020-02-11
>
jasonbell09:02:28

Hailageddon…..

otfrom09:02:48

morning. bit blowy here still. snow has stopped tho

thomas10:02:30

still windy here.

otfrom14:02:36

so... I have a set of IDs that are ones that I want to exclude. Is it better to use them as a set and compare them to the ids I want to get rid of, or map over all the records, adding a flag and then excluding records where the flag is true?

otfrom14:02:16

I suppose it depends a bit on what I want to do with the data later and the map and assoc a new key with a value gives more flexibility

jasonbell15:02:41

Is there a chance the records will get used in the future, will their state change?

jasonbell15:02:02

If I know I’m excluding and removing then I use a set of ids.

otfrom15:02:23

hmm... I think I will want to be able to do analysis on the ones that I flag, so I probably should, but YAGNI

otfrom15:02:26

and I don't need it atm

otfrom15:02:34

I think this is why I'm torn

jasonbell15:02:16

Write two functions. Call one natalie and the other imbruglia and compare the two then.

😂 4
otfrom15:02:03

@jasonbell I think you need to follow that up with "I'll get me coat"

🧥 8
jasonbell15:02:32

@otfrom You do know @thomas will be secretly laughing at this 🙂

thomas15:02:02

I'm 'fraid that wasn't secretly.

thomas15:02:21

it must be all the CO2 getting to my head.

jasonbell15:02:03

I’ve watched so many episodes of House that I forgot how annoying and sarcastic I was. 🙂

jasonbell15:02:12

And I’ve got a walking stick

thomas15:02:21

you know it this is your role here @jasonbell... to provide the entertainment on this other while boring day.

jasonbell15:02:38

I’ll let Jade know

👍 4
fmjrey16:02:01

@otfrom you can still create a set of IDs and keep it warm, data is always useful, and later it can become a predicate, a transducer, etc

otfrom16:02:25

yeah, I'm using it as a predicate now to remove the ones I don't want. It is easy to recreate from the source data. I'm probably good as I am atm, but as it was a bit 6 of one half dozen of the other I thought I'd canvas for opinion. 🙂