# What returns will I get from equities going forward? – Part 2

In the first part of this series here, we discussed on how to evaluate valuations and plug it into our future returns estimates.

Today, we shall solve the next part of the future returns puzzle – Earnings.

Let me be honest upfront. I don’t think I know an exact method to predict earnings growth. In fact I don’t think I ever will 😦

So acknowledging this inability of mine, the idea here will be to work around with a simple framework which is not intended to be precise, but rather can be a good starting point in our conversations about equity return expectations.

Now that we are done with all caveats, let’s dive in..

How do we estimate future earnings growth?

### Carl Jacobi to our rescue

Jacobi, a German 19th-century star mathematician, believed that the solution for many difficult problems could be found if the problems were expressed in…

View original post 988 more words

# Share: Harry Potter and the Methods of Rationality

You have to, you can’t progress as a scientist otherwise, there’ll be a roadblock in your way, an authority you can’t contradict. Not every change is an improvement, but every improvement is a change, you can’t do anything better unless you can manage to do it differently, you’ve got to let yourself do better than other people! Even your father, Draco, even him. You’ve got to be able to point to something your father did and say it was mistaken, because he wasn’t perfect, and if you can’t say that, you can’t do better.”

# Gaussian Mixture Models.. GMMs

## Gaussian Mixture Models

• A probabilistic model
• Assumes all data points are generated from a mixture of finite no. of gaussian
distributions
• The parameters of the gaussian distributions are unknown.
• It is a way of generalizing k-mean(or k-medoid or k-mode for that matter) clustering to use the
co-variance structure/stats as well as the mean/central-tendency measures of latent
gaussians.

## scikit-learn

### Pros:

• Fastest for learning mixture models
• No bias of means towards zero, or bias cluster sizes to have specific structures

### Cons:

• When there’s not enough points per mixture, estimating covariance matrices becomes
difficult
• Number of components; will always use all the components it has access to, so might need
missing or test-reserved data..

• No. of components can be chosen based on BIC criterion.

• Variational Bayesian Gaussian mixture avoids having to specify number of components

# Word_2_vector.. (aka word embeddings)

## Word 2 vector:

• word 2 vector is a way to take a big set of text and convert into a matrix with a word at
each row.
• It is a shallow neural-network(2 layers)
• Two options/training methods (

### CBOW(Continuous-bag-of-words assumption)

• — a text is represented as the bag(multiset) of its words
• — disregards grammar
• — disregards word order but keeps multiplicity
• — Also used in computer vision

### skip-gram() — it is a generalization

of n-grams(which is basically a markov chain model, with (n-1)-order)
* — It is a n-1 order markov model
* — Used in Protein sequencing, DNA Sequencing, Computational
linguistics(character and word)
* — Models sequences, using the statistical properties of n-grams
* — predicts $x_i$ based on $x_(i-(n-1)), ....,x_(i-1)$.
* — in language modeling independence assumptions are made so that each
word depends only on n-1 previous words.(or characters in case of
character level modeling)
* — The probability of a word conditional on previous n-1 words follows a
Categorical Distribution
* — In practice, the probability distributions are smoothed by assigning non-zero probabilities to unseen words or n-grams.

• — Finding the right ‘n’ for a model is based on the Bias Vs Variance tradeoff we’re wiling to make

## Smoothing Techniques:

• — Problems of balance weight between infrequent n-grams.
• — Unseen n-grams by default get 0.0 without smoothing.
• — Use pseudocounts for unseen n-grams.(generally motivated by
bayesian reasoning on the sub n-grams, for n < original n)

• — Skip grams also allow the possibility of skipping. So a 1-skip bi(2-)gram would create bigrams while skipping the second word in a three sequence.

• — Could be useful for languages with less strict subject-verb-object order than English.

• Depends on Distributional Hypothesis
• Vector representations of words called “word embeddings”
• Basic motivation is that compared to audio, visual domains, the word/text domain treats
them as discrete symbols, encoding them as sparse dataset. Vector based representation
works around these issues.
• Also called as vector Space models
• Two ways of training: a, CBOW(Continuous-Bag-Of-Words) model predicts target words, given
a group of words, b, skip-gram is ulta. aka predicts group of words from a given word.

• Trained using the Maximum Likelihood model

• Ideally, Maximizes probability of next word given the previous ‘h’ words in terms of a softmax function
• However, calculating the softmax values requires computing and normalizing each probability using score for all the other words in context at every step.
• Therefore a logistic regression aka binary classification objective functionis used.
• The way this is achieved is called negative sampling

# Doctors, Ethics, and expert problems

## Doctors, Ethics, Surgeons, Expert problems:

* NNTaleb has been writing about [expert problems](http://www.zerohedge.com/news/2017-02-07/not-fascism-nassim-taleb-warns-theres-global-riot-against-psuedo-experts) for a while.
* He has also mentioned about [doctors](https://medium.com/incerto/surgeons-should-notlook-like-surgeons-23b0e2cf6d52) belonging to experts class for a while
* I’ve had experience with doctors, that suggest a similar problems(non-clarity/transparency
about conflicting interests), and I wrote some general set of advice [here](https://softwaremechanic.wordpress.com/2016/08/07/advice-to-doctors/) and a short related announcement [here](https://softwaremechanic.wordpress.com/2016/08/03/notesthoughts-from-waiting-at-the-labour-ward/).

* However, NNT also has this [quote](https://en.wikiquote.org/wiki/Nassim_Nicholas_Taleb)
* So I’m calling out the [specific people, hospital and incident](http://www.lakshmimadhavan.com/dr_madhubala_manickavasagam.php) that triggered me to write that article above.
* This happened last year 1st of August and since there was a whole lot of emotions involved
from my side on the incident, I’ve waited to let them all get out of my system, and almost
a year later, I’m still convinced, this needs to be a specific pointing post at specific
people , hospital and incident.

* In the time since then, I’ve spent a lot of time soul-searching, trying to read Doctors

* I really liked the answers by [Dr.Vinay
above, but quora is messed up^2 and banned him based on BNBR policy reporting by a horde
of nationalist trolls(Stay tuned for politics/policy related post for that one).

## Disclaimers:
I wrote a set of disclaimers for the advice for docs post, add these too.

* I am not a doctor, or for that matter in any ways working in the medical field
professionally, now or in the past.(doesn’t look likely in future either, but that’s
later)

* I am not hiding behind anonymity, this blog is at best pseudonymous, but for this post, I
am using my real name, which can be googled and found.

* I am aware of the complexities of biology and medicine, and how much surprises it has
thrown up, just when science thought it knew humans.

* I have two Doctors in the family(a aunt and an uncle) and have some idea of the pressures
they face, and habits they pick up.

* I did no research or enquiry on the hospital or Doctor before choosing them. The
patient(my wife) was insisting on them, and I had no way of gathering reviews/evidence.

* I won’t even bother claiming, I was being rational at the moment.

* I do claim, I could have and did guess the potential side-effect (of using a sublingually
administered, hormone pill to induce labour) simply by my basic understanding of biology,
but did not raise the question or confront the doctor(deferring to their judgement),
till the nurses started saying the blood pressure is not stable^6, we might have to operate.

* Chief Doctor Madhubala^3 may be a good surgeon and probably has a primary focus on surgeries.

* However, she’s shuffling between atleast 2-3 roles(a physician, surgeon, reputation
manager, PR representative, hospital administrator, etc.)

* She’s clearly insecure about her knowledge of the drugs administered, and their
side-effects, risks vs benefits tradeoffs, and her judgement.(aka physician role, See my

* She really needs to get hold of her emotions, and not drop back to the
[intimidation/dominance game](https://en.wikipedia.org/wiki/Dominance_hierarchy). Aka
switching to English (to distract) works only on some types, not on others. (as evidenced,
by taking, do you know you’re in my property and asking me questions)

* Taking a hi-fi (“Who-are-you-to-question-my-treatment^4”) only works with people who’ve had
a history of being intimidated by “Experts”

* She showed no sign of awareness about the conflict of interest involved in the roles, she
seems to be playing.

* She’s fairly hard to catch/meet (as the patient’s husband) as they have ladies only
inspection sections, and use internal paths to navigate.(in effect avoiding the relatives)

* There’s signs of un-awareness of responsibilities of roles(in terms of treatment), as
evidenced by her question, “Do-you-know-how-much-time-I-spent-with-her?”(She’s expected to
make judgement on best treatment, and explain to the patient her top few choices of
treatment. Being nice is good, but secondary responsibility. I understand some
sections/types of patients, don’t want to know the details of treatment, but that doesn’t mean you fail

* She clearly, is too afraid of risks and of losing her image/status/assets over the
patient’s welfare. (as evidenced, by a threat/blackmail to expel the patient).

* There’s not enough transparency^5 of treatment given. As I mentioned during treatment, the
patient should know, and after discharge, there should be medical history sheet of sort
given to the patients.

* After you’ve made the threat of expelling a patient, and the patient’s mom, has fallen to
your feet etc.. All actions, like for example assigning a separate room, and letting the
husband, be with the wife etc.. simply seems like a PR stunt, rather than genuine,
concern. (Especially, after all those moves, you pulled, when confronted in private.)

## Conclusion:
* Eventually, She did do a C-section and delivered my daughter safely without any
complications. Thanks to that.

* I do conclude that she’s not caught up or upto date in her treatment research .

* Ironically enough, writing this blog post is more likely to bias the set of patients the
hospital receives towards the bunch of people who’re vulnerable to all that intimidation.

* That is, if this has any effect at all, it will be on the people who read and are
reasonably regular readers and then it will convince them to choose a different hospital.

* So this blog post might actually become a positive-feedback loop for the very same
behaviours and incidents that caused it to write in the first place.

* I struggled with an effort at guessing, the impact of writing this in public vs sending a
private e-mail, but without any real numbers or demographics of the patients the hospital
it caters to, I could only make guesses. and none after that(i.e: future changes/processes
at the hospital, introspection/self-awareness on the Doctor etc..). So I won’t claim i
wrote it as a PSA(public service announcement), but I’ll observe that it is a relief to
have written this out.(Make what you will of it).

* I’ll finish with my [favourite humourous quote from Douglas Adams](https://softwaremechanic.files.wordpress.com/2017/06/da.jpg).

2. SideRant: Dear [quora founder](https://www.quora.com/profile/Adam-DAngelo), while I understand the reason for your BNBR policy, and how algorithmically it works in the first world, you really, really, have to find a way to handle the crazy, hordes of masses from the non-first world. it doesn’t necessarily have to be manual, but get some better training data atleast. (For ex: mechanical turk, but they don’t do Indian audience, may be try [Squadrun](https://squadrun.co/). Really try to get people to review someone’s profile history and rate his trustworthiness, may be that help build a NN model to predict a person’s rateworthiness(segregate/segment by country/location if needed). Don’t just ban good writers, who are actually helping.

3. Or as I nicknamed her Dr. Tasmac Bala

4. Ironically enough, I was questioning whether she explained the risk-benefit tradeoff to her
patient and not her judgement or choice of treatment.

5. I am a little bit conflicted by the necessity of this point, as I haven’t done any hospital
administration. My reading on quora and interactions with some of the Doctors suggests that
requiring it by law, only makes the “Doctors too cautious and biased towards inaction till
emergency.” So as a policy, better to study different countries and implementations and results
before concluding anything.

6. Which is a side-effect of sub-lingual hormonal administration

UPDATE: Apr.17-2018: Here’s  an additional link suggesting as to what could be happening. (It originally has the US industry in mind, but probably transfers well to India)

# Share: Harry Potter and the Methods of Rationality

Did some plans call for waiting? Yes, many plans called for delayed action; but that was not the same as hesitating to choose. Not delaying because you knew the right moment to do what was necessary, but delaying because you couldn’t make up your mind – there was no cunning plan which called for that.
Did you sometimes need more information to choose? Yes, but that could also turn into an excuse for delaying; and it would be tempting to delay, when you were faced with a choice between two painful alternatives, and not choosing would avoid the mental pain for a time. So you would pick a piece of information you couldn’t easily obtain, and claim that you couldn’t possibly decide without it; that would be your excuse. Although if you knew what information you needed, knew when and how you would obtain that information, and knew what you would do depending on each possible observation, then that was less suspicious as an excuse for hesitating.

# Share:The Pact

you’re lost. The implement requires a more intimate knowledge of yourself. Who are you, and how do you address the rest of the world? Some people find this an easy decision to make. They know they are warriors at heart, or thinkers. For others, it’s a very nuanced choice. A small few rush into it, and they find they’ve crippled themselves.”

# Avoiding being a ‘trophy’ data scientist

Recently I’ve been speaking to a number of data scientists about the challenges of adding value to companies. This isn’t an argument that data science doesn’t have positive ROI, but that there needs to be an understanding of the ‘team sport’ and organisational maturity to take advantage of these skills.

The biggest anti-pattern I’ve experienced personally as an individual contributor has been a lack of ‘leadership’ for data science. I’ve seen organisations without the budgetary support, the right champions or clear alignment of data science with their organisational goals. These are some of the anti-patterns I’ve seen, it’s non-exhaustive so I provide it.

The follow is an opinionated list of some of the anti-patterns.

1. I’ve written before about data strategy. I still think this is one of the things that’s most lacking in organisations. I think a welcome distinction is that data collection which needs to happen before data…

View original post 703 more words

# Share : The Pact

Better to seem unfriendly and overly emotional than risk letting an enemy inside safe territory. “
Hmmm…. the robust strategy… perhaps why stoic behaviour is getting popular in the age of no war.

“I’m doing okay enough that I treated myself to my first big nonessential purchase.”