Well Heather, just to fill you in, so for the Snap-Fu yesterday, took Canlytics to Las
Vegas to attend the Cannabis Conference here.
So doing a bit of networking and also trying to learn as much as I can, you know, that
we can share with the group and hopefully everybody can learn from that.
So it's good to see you.
I see Keegan.
Hopefully more people roll in.
Should be good.
Well I can go ahead and share a bit and then we can just take it from there.
Maybe a shorter one this morning, but something's better than nothing.
Yay.
I heard a person.
Great, so just to share a bit with you, so here at the Cannabis Conference here in Las
Vegas, so I just thought I would share with you just some of the, you know, the topics
that have come up and, you know, show where the data that's publicly available could be
used to analyze some of the topics that were brought up.
So it's a lot of cultivation, so it's a good place to really get motivated to start a cultivation.
And so what I'll take away from this is, you know, now is as good a time as any to go ahead
and apply for a license and get going.
So there's, of course, you want to get a lot of planning in, and so, you know, Sun Tzu's
got a motto that, you know, whoever plans the most tends to win.
And so that's a key, but from what I'm seeing, the people who've been successful are the
people who started, you know, they just started somehow, some way, and they've done quite
well for themselves.
So lesson learned is go ahead and start, and there may be a learning by doing, so there
may be a learning curve as you go, but now is as good as time as ever to jump in.
And so, you know, so the question is, you know, where and how.
So that's, you know, the licensing.
And then, of course, they talked about, okay, as a cultivator, you know, what are some of
the things that you may be looking for?
So what are some of these data points that you're looking for?
And so one thing that they talked about that we can analyze here is basically we're trying
to break down cannabis into, you know, four or five groups here.
So that way, you know, you can kind of distinguish between, okay, what are you getting?
What are going to be the effects?
So they've identified essentially five main types.
You've got your high THC to CBD.
So this is going to be the intoxicating cannabis.
And you know, you may not be on the couch.
Next, there's the near unitary THC to CBD.
And so these are going to be your hybrids.
And so these are going to give you a mixed effect.
So these, you know, you may wind up on the couch.
And you know, they're going to be a bit more sedative, relaxing, if that's what you're
looking for.
Then there's type three, which is your high CBD to THC.
And so, you know, of course, the higher the CBD to THC ratio, then the less intoxicating
it's going to be, and these are going to be the people looking for the more medicinal
effects, people looking for soothing relaxation, passive relaxation, and you know, they're
still looking to be quite present.
CBG.
And so those are the three main types.
So you can really stick to those.
And then just if you were going to toss in two more types, you could toss in the CBG,
where you know, CBG is present and ideally present at above average concentrations.
And then the fifth type is, you know, no major cannabinoids.
And then this will be a little trickier to parse out and identify.
So I thought today, why don't we try to identify the first four types?
And we can do this with Washington state data so we can get quite granular data.
We can actually get every data point through the Freedom of Information Act.
So we can get the whole market snapshot and we can look at these four types here.
So without further ado, just going to go ahead and read in the data.
And we'll be off to the recess.
Okay, so we've got a handful of data points.
So let's give it 30 seconds or so.
And then the first thing I'm going to do is just look at all the flower data.
We could look at concentrates and we may actually do that next.
But just for simplicity sake, just so we're looking at apples to apples, we'll be looking
at flower to flower.
So almost two million observations, about a million flower samples of the, you know,
approximately 2400, 2400, 2400, 2400,000 flower samples, about 17,000 or almost 18,000
at CBG.
So that's about seven and a half percent of all the samples.
So you may even classify this whole group here as your type four, your cannabis with
CBG.
What I technically defined it as was CBG above average concentrations.
So what we can do is, well, we can just take the average CBG present in the flower with
CBG, which is about 0.8%.
So then we could identify all the samples with above average CBG.
Let's see if we can look at that data.
So we have no CBG.
Let's see what columns we do have here.
Oh, that makes a lot of sense here.
Now let's just look at a histogram just to see what it may look like.
So this is a factor.
So we may have some with miscoding.
So we're going to go ahead and drop the outliers.
That way we may be able to get a better plot here.
So real quick, let's just restrict this to the bottom 95%, the bottom 95% core type.
So they're with me here while we get this nice and plotted.
So we're just restricting this.
And then we'll see if we can't get a decent histogram once we exclude that outline.
So here's a better histogram here.
And so these are going to be the presence of CBG in our type 4.
So we're basically saying, OK, type 4 is basically going to be about 1%.
So we actually defined it earlier as 0.8%.
So it's going to be about 0.8%, about 1% or above CBG content with a logarithmic distribution
here, where you've got the top end of the distribution just shy of 5%, so about 4.5%.
So let's just go ahead and look at the whole distribution of CBG.
That's right.
And let's exclude these for outliers as well.
So bear with me while we just look at it.
Let's look at CBG with the outliers as well.
So once again, we actually see a logarithmic scale for CBG with the mean at about 0.8%.
So I think that's the concentration you're looking for if you're trying to grow a CBG
type 4 strain, is you're looking for 0.8%, 1% or above.
OK, so we've drummed that horse into the ground.
So now let's look at type 1, 2, and 3.
So we can probably make short work of this, believe it or not.
So we basically need to define the THC to CBD ratio here.
So here we're just taking, actually we actually want a CBD to THC ratio.
So let's reverse this real quick.
Now we're going to calculate a CBD to THC ratio in the flower.
Let's see if we can do that without too much trouble here.
All right.
We can, once again, we may need to drop outliers for plotting, but let's see if we can't get
it to Instagram nonetheless.
All right, so let's go ahead and identify our three types here before we drop the outliers.
So simple enough.
Define type 1 as high THC to CBD.
Other ways, low CBD to THC.
So we're going to define low as less than 0.9 CBD to THC ratio.
So this is just an arbitrary number that I just pulled out of my hat.
So this may need more rigorous definitions here.
So just starting somewhere just to show you proof of concept.
So we're going to locate all the data.
So we want basically all of the flower data where the THC, or actually where the CBD to
THC ratio is less than or equal to 0.9.
So simple enough.
Let's count how many there are.
Great.
And so let's calculate, OK, what is that out of all of the flower samples?
Well, we may need, this could either just be the breakdown of the market or we may need
to change our definitions of CBD to THC ratio.
So it's looking here like about 92.5% of all of the flower sold is type 1.
And that may very well be the case.
You may, type 1 flower may be in high demand.
So let's go ahead and identify these other two types just for completeness sake.
Bear with me as I code this up in front of you.
So basically we want the CBD THC ratio to be greater than 0.9 and we want it to be less
than 1.1.
And that should be our type 2.
And let's calculate that as a proportion of the total.
About 2%.
Like I said, we may need to widen these bounds a bit for the type 2 identifier.
So that's why it may be nice to actually look at a scatter plot here.
That would actually probably be a good idea here.
So let's identify type 3 and then let's look at some scatter plots to begin to visualize
the data.
So real quick, type 3.
It's going to be everything with the CBD THC ratio greater than or equal to 1.
Simple enough.
Calculate that as a percentage of the total for completeness sake.
About half a percent.
So that may just be how the market shakes out.
The market may just be looking for a low proportion of the high CBD THC.
And so that could be a quite interesting data point.
One second, they're saying, I apologize for the hot rod.
Okay.
So that may be saying, okay, the market may actually not be demanding very much high CBD
cannabis.
So if you're in Washington, you may want to look at these numbers and try to position
yourself well.
Right?
You may, there may not be much competition for the high CBD flower if there's only a
small amount being grown.
So it could be a place to niche yourself.
And there was a speaker here at the cannabis conference who did just that in Oregon.
And so it can be done.
So maybe there's more room for type 3.
Maybe type 1 is quite saturated in the market.
So possibility.
Enough of just looking at the raw data.
Let's look at a couple of plots here.
So let's see if we can make a few scatter plots here.
So first things first, let's see if we can't just look at a scatter plot of just the flower
data as a whole.
So here we just want to look at flower data.
Well we will need this plotting library.
And yes, it's getting a little rowdy here.
So hopefully we can finish our analysis without too much more noise for you guys here.
We've got a lot of data that we're plotting.
So we may, it looks like, want to exclude outliers.
So let's do that and see if we can't get a better visualization of this data.
So as you've noticed, excluding outliers is a go-to strategy of mine, at least for creating
visualizations.
It just, as you see these outliers, they ruin the scale.
So it's hard to visualize the data.
So simple enough.
We'll restrict to the bottom 95% quartile.
Because we're basically saying, okay, that top 5% they're outliers.
We're not sure if that's miscoded data or what have you.
Albeit that can be an interesting segment of the data set.
So you don't want to just throw away the top 5% in your analysis because they're often
some of the most dynamic observations.
So let's create a quick plot here.
Here's an upper bound where...
So we may actually need to restrict this twice, once on CBD and once on THC.
Okay.
So bear with me here.
Bear with me.
So this is just sort of ad hoc.
We could clean this up later.
We're just trying to get this plot made real quick.
Great.
Do we now have...
That is quite the scatter plot, isn't it?
It looks like there's something just all across the board here.
So that...
Let's put CBD on the y-axis here because that would make more sense.
Let's try this one more time.
So this is just going to be a plot of CBD to THC of all flower data in Washington State.
So let's go ahead and put some labels on this just so we can see what we're looking at here.
So CBD to THC.
Like I said, hot rods.
Okay.
So here we have a plot of CBD to THC.
And so as you can see, we basically have something all across the map.
There's strains with high CBD, low THC.
There's strains with high THC, high CBD.
So there's something all over the map.
So that's why we're trying to break this, hopefully, into four groups.
So we basically have quadrant one.
So we'll start with quadrant one.
So quadrant one is high THC, high CBD.
So those are going to be your near unitary, perhaps, your near unitary cannabis.
Then you're going to have quadrant two, low THC, high CBD.
So that's going to be your high CBD strains.
And then it looks like the quadrant three and quadrant four are type one, where it's
basically high THC, low CBD.
So let's see if we can't plot the four different types and perhaps be able to have a bit more
definition.
Once again, there may have to be some fancy footwork done to handle outliers, but we'll
deal with that as the need arises.
So bear with me putting CBD on the y-axis.
Right?
So now let's see if we can't plot the four types.
And this could be interesting here.
Right, so let's do, we've done it, but now let's repeat it, restricting the outliers,
just so we can visualize the majority of the data better.
So what we can simply do, toss the restriction.
We'll just define the restriction before we define the types, simple enough.
And we'll simply define our types with the restricted data set here.
And hopefully we get a decent looking figure.
This is the first time I've, type four will remain the same.
We may just want to use type four data where we've restricted the outliers.
So let's recalculate these three types here, simple enough.
And we're going to use type four data, which has been restricted.
And let's make this figure one more time.
See if we have a bit more definition.
Interesting.
So something didn't quite take here.
Somehow that didn't work quite well.
Okay, so another strategy that we're going to do is let's just calculate types with the
full data set.
So going back and we'll just basically going to do what we did here.
And like I said, I'm just doing this kind of quick and dirty, just so we can get these
figures up.
Let's go ahead and restrict these types to the 95% quartile.
Okay.
So this may or may not work, but it's worth a shot here because I think we could get a
really, really interesting figure.
So just bear with me as I put this up and 30 likes.
Okay, so three.
Simple enough.
We may have removed the outliers from the data to the extent that we may now be able to plot
it in a decent manner here.
And let's see what we have.
Okay.
We still have not, I still not ideally removed the, I still have not successfully removed
these outliers here.
That's okay.
We'll do what we did with the restricted flower data essentially.
So bear with me five more minutes or maybe hopefully less than that.
And then we can get this sorted away.
All right.
Thank you.
The traffic's picking up a bit, so we'll get this plot made and then we may go ahead and
conclude a bit early for today.
So my apologies for sort of this impromptu meetup.
So next week we'll be back to the regular crunching numbers back in Oklahoma actually.
So that will be fun.
So thanks for bearing with me for this sort of impromptu meetup and hopefully we can get
back on track for next week.
So just to go ahead and see this through.
We can finish this really quick without too much trouble.
And the nice thing about coding, reuse, reuse, reuse.
So bear with me as we get this sorted up.
And the third time does the charm.
This maybe will have excluded the outliers sufficiently that we can get a decent plot.
By the way, that's a T. What type of T?
Well this is bizarre.
So this is our plot.
And so apparently our categories may not have quite classified the cannabis as we may have
desired.
Because we were thinking, okay, this may be quadrant one, two, three, and four here.
And here what we're seeing is basically we're defining everything.
And we'll actually want to toss some legends on here.
So we'll need to see if we can do a legend on this real quick.
I think we can just hopefully we can just hopefully we can just toss a label on this
data here.
I'm not certain.
So let's just try this real quick.
It would be nice to know which one type two and which is type three.
Which one's the green exactly?
So bear with me while we get this legend.
Okay, if we toss this legend in here.
Let's see if.
Okay this didn't quite do the trick.
It doesn't work.
It's not the end of the world.
We just kind of.
Okay so there we are.
So as I was thinking the type one is we're defining that is you know that's what we're
defining is 90% of all cannabis.
Interestingly, so the type two almost non-existent.
At least with our definition we need many to broaden our cutoff here.
And we'll do that here in one second.
And then we're basically saying okay the type three is you know this bottom segment.
So quite interesting.
Let's add in type four.
See if the visualization stays decent.
Heavy outliers one hopes.
Okay it looks like type four has outliers as well.
So just for completeness sake and I'm curious to see type four plotted.
So why don't we just go ahead and basically we'll just restrict the type four data removing
the outliers the same way we did with type one two and three.
Okay and so now we're treating all the data the same which is.
Interesting.
So honestly what I make of this is it looks like these high CBG strains also have high
high CBG strains also that appears to have high CBD.
Let's just make sure I did this correctly.
Everything yeah everything looks about right.
So that's just quite odd.
And so that's why maybe the type four don't fit so nicely into this box here is because
they are in fact you know a whole nother type of their own.
So that's maybe maybe this plot.
It may make the most sense just type one two and three.
So yes yes so that's an interesting interesting observation.
And just to round this out finish it up.
Let's just go ahead and remember our our our limits here were sort of ad hoc.
So why don't we just sort of define those and then we can you know see if we can't.
Parameter hunt essentially do to see if we can you know define these into quadrants.
This isn't really how I'd recommend doing things.
It may be nice to have a bit more of a theoretical approach.
But for now let's just let's just crunch some numbers with the time we have here.
So let's just define these limits here.
Maybe the high THC limit.
Maybe we'll lower that to zero point five and then the high CBD limit.
Maybe we'll raise that to one point five.
So now we can substitute these into our analysis to make it dynamic.
So I can find type two and then we'll identify type three.
All right.
Let's basically just rerun this chunk of code and just redo our analysis.
This may take a hot minute.
Maybe 10 seconds and then.
Well we have a bit more distinction here but it's still this quite similar quite similar
look here where you've got real small segment of the market as type two near unitary.
Then you have a small amount of the market type three.
The majority of the market type four.
So let's just lower these limits real low.
And see what this may look like.
Basically did three scenarios narrow bounds medium bounds wide bounds or oh the wide bounds
is quite interesting here.
So if we if we do wide bounds then we actually get a bit better distinction.
OK what's type two what's type three and what's type one.
And so I think this is a interesting interesting plot here because it does begin to show how
Lauer appears to have at least two different types.
It looks like type one and type I mean type two and type three maybe similar.
They're they're kind of clustering together.
They may be distinct.
However, they're definitely different than type one.
So quite interesting observation.
And then what's going on with type four.
Is this an outlier issue or are they a special group of their own.
And so the type four remember we defined as.
And so here let's look at just type four in isolation.
So type one two and three and then type four.
Is just real real peculiar where you have some with just staggering high levels of CBD.
So just so you know like 16 percent CBD is staggeringly high.
I think that's perfectly possible.
It is.
Yes.
I've definitely seen CBD strains testing that high.
It's rare.
Right. These are you know this this rare this this rare group of strains of cannabis that
produce CBG which is uncommon and they produce some of them staggeringly high levels of CBD.
And so this may be something to keep an eye out for in the future.
And then type five no major cannabinoids.
We may be able to say that.
Maybe this is type five.
Right.
Hold on.
Let me re plot this.
Something's going.
So my.
My console is not behaving super well.
So let's just plot this one more time.
Just so I can point at it while I'm talking about it.
So basically what I was saying was this may actually be type five where you know the delta
and also now I'm starting to wonder did we did we exclude the concentrate successfully
here because cannabis shouldn't have that high a level of THC.
So we may have we may not have successfully isolated the flower data.
So I want to revisit that because the delta nine really should not be above above you
know 30 35 percent.
So what I'm thinking here is we've got type one type two type one type two type three
and then I'm thinking these must be concentrates.
So how they got mixed in.
I'm not 100 percent certain that I want to read.
Look at this analysis here.
So now after casting complete uncertainty over the entire analysis here I'll go ahead and
be wrapping it up.
So long story short there's something going on here with these different types of cannabis
but I think it clearly requires further analysis at least you know here in the Washington state
data.
So there's plenty to be done here.
So this was just a crude you know proof proof concept that you can take this data you can
calculate these statistics and you can create some quite interesting visualizations.
So so that's you know what's been going on here at the you know the cannabis conference
you know I'll I'll try to share my notes with you and you know just share with you what's
going on.
But you know a lot of it's just it's just kind of time to look at the data especially
if you're on the cultivation side right.
So data and planning go hand in hand.
All righty then well Heather thank you for coming back today for an impromptu meet up
of the cannabis data science group.
So so thank you for coming back and we'll try to get the rest of the crowd back back
for next week.
So it was just it was a snafu yesterday.
I meant to be here but you know you live and you learn and you know you can only you know
approach the and this actually may be a good example of sort of the lessons learned in
the cannabis industry right.
So nothing ever goes to plan your contingency plan needs a contingency plan.
So and that's sort of the lesson that people are learning in the cannabis industry no matter
how much you plan nothing ever goes to plan.
You're going to have to think you're going to have to move quickly on your feet and there
could be some disasters there could be there could be some fires that need to be put out.
And so I think that's that's just what to keep in mind is move quick get going.
Now is better than never and take your adversities as they come.
So and you'll be successful.
So those I think are the major takeaways and you know learn from smart people.
So that's what I do try to find people that are smarter than yourself and and immerse
yourself with them.
So that's why I'm here.
There's a bunch of people here that are much more knowledgeable in the cannabis industry
than myself.
So just here to learn and then try to convey some of that knowledge the best I can to everyone
else in the group.
So I think I'll go ahead and wrap it up a little early today taking up a seat here at
the cafe and I'm sure the waiters looking to get a yeah someone else here.
So I'll quit taking up space.
So thank you for thank you for attending and next week we'll be back to normal back in
Tulsa Oklahoma Frenching numbers and we'll be doing we'll be back next week to doing
our cannabis data science meetup group estimate of the size of the entire industry.
So it's not saying we'll conclude next week but we'll be back at it.
Thanks awesome Heather.
All right.
Thanks for bearing with us and thank you for attending and keep your nose to the grindstone.
Thank you.
Bye.
Bye now.