# All articles with 'Microsoft Excel Formulas' Tag

Late. Jayaram, my uncle is also a teacher. When I was a kid, I used to spend a lot of time with him, learning all sorts of things. He taught me chess, maths and so many life lessons. I remember one such lesson very vividly. One day, he asked me to do something. I did it in a very long way. After seeing me struggle for several minutes, he chipped in and showed me how to do it easily. He then said, **“when someone asks you where your nose is, you don’t twist arm around your head. You just point to your nose directly.”**

The idea is that when you have a direct, simple way to do something, you should use it.

**Nose and pivot tables… how are they connected?**

We are coming to the point. Read on for full case study and solution.

Continue »Here is an interesting problem to keep your brain cells fight boredom on this Friday & weekend.

Let’s say you have some data like above.

And you want to know, for a given customer name (in cell G4),

- What is the most frequent quantity?
- What is the most often purchased item?

How would you write formulas to get these answers?

Continue »In this amazing guest post, the winner of our 2016 dashboard contest – Chandeep – Explains how he constructed the jaw dropping beauty (shown above) using Excel, creativity, love and sweat. Grab a full cup of coffee (or whatever liquid fancies you) and read on. Take lots of notes and play with the ideas in Excel while reading to maximize your learning.

Thanks Chandeep.

Continue »**Let’s talk about the untrimmable spaces.**

We all know that TRIM() removes extra spaces from the beginning, ending and middle of a text.

So for example, if A1 has ” something and one more ”

TRIM(A1)

will give “something and one more”

We can use CLEAN() function to remove non-printable characters (like the ASCII codes 0 to 31). Of course, SPACE is technically a *printable *character, so CLEAN() won’t remove spaces.

**The untrimmable spaces…?**

The other day *Sreekanth *emailed me a sample of data and asked, *“how do I remove the spaces in this list and convert them to numbers?”*

Naturally I tried to TRIM().

But the data won’t budge. See above.

Hmm, let’s investigate why.

Continue »**First a quick personal update:** There has been a magnitude 7.8 earth quake in NZ on 14th November 2016 early morning. It is centered in Kaikoura, which is about 250 km away from Wellington. We did feel several shakes and after shocks. It has been an interesting and often scary experience. But my family is safe. I feel very sad for the all the damage and the loss for families in NZ. If you suffered from this quake, My prayers and thoughts are with you.

Yesterday, a friend asked me an interesting question. He has school distance data, like above. He wants to know which is the closest school for each school.

There are a few ways to answer this question. Let’s examine two approaches – formulas & pivot tables and see the merits of both.

Continue »**4**Comments }

## CP056: So which formulas you should care to learn?

*in*Chandoo.org Podcast Sessions

Podcast: Play in new window | Download

Subscribe: iTunes | Android | RSS

In the 56th episode of Chandoo.org podcast, let me answer the chicken and egg question of Excel users. **How many formulas should you care to learn?**

**What is in this session?**

In this podcast,

- Two personal updates
- 3 legs of formula writing
- Function knowledge
- Operators
- Referencing

- 6 categories of must-know functions
- Basic math
- Conditions
- Lookups
- Text
- Date & time
- Work specific

- Closing remarks & resources for you

**16**Comments }

## How many formulas should you learn? [Weekend Poll]

*in*Learn Excel

Over at twitter, @for_the_moves asks,

@For_the_moves Same as growing your vocabulary. Remember, words (or functions) = ideas. the more you know, the better you can think.

— Chandoo.org (@r1c1) October 12, 2016

That got me thinking. *How many functions should you care to learn?*

**17**Comments }

## Finding if a cell has 7 in it… [Pattern matching in Excel]

*in*Learn Excel

Imagine you work at MI5 as a HR officer. **You want to find all agents who have license to kill (licence 7)**. Your data looks like above.

**How would you go about it? **

If you filter the list or use FIND() or SEARCH() formulas, you will end up with agents who also have licenses 77, 17 or *not7*. So how would you solve this problem?

Of course, you do what any smart person does. You summon Excel and ask it nicely by using some wicked pattern matching logic.

Continue »**5**Comments }

## CP055: “Yes, I am back” edition (and a bonus Excel tip)

*in*Chandoo.org Podcast Sessions

Podcast: Play in new window | Download

Subscribe: iTunes | Android | RSS

Ladies & gentlemen, its time we revived the much loved Chandoo.org podcast. In the 55th episode, I do a lousy imitation of Arnold Schwarzenegger’s famous “I will be back” and tell you why there was such a long gap between episodes, my plans for reviving our podcast and more.

**What is in this session?**

In this podcast,

- Why there was such a long gap between last and this episode
- What next?
- How to extract every 6th item from a list?

Finally, spring weather showed up in Wellington this week. We cashed it as much as possible by going on treks, cycling trips, more treks and of course doing laundry.

Anyways, I don’t have time to blog. I must go out and help kids with some cycling. But I want to keep you busy this weekend. So here is a fun homework problem.

**Does my range have all numbers from 1 to n?**

Let’s say you have a range called ** range **(duh!). And you want to check if

**range**has all the numbers 1 to n (say n=5) in it, each number appearing only once (no more, no less). You can assume the named ranges

**range**and

**n**in your formulas.

See above examples to understand the problem.

So go ahead and post your formulas in the comments section. I will sneak in whenever I can to look at all your creative answers.

Continue »Let’s say you have a date in A1 and want to find out future date after 2 years, 4 months and 9 days.

Here are a few formulas you can try.

- =A1 + DATE(2,4,9)
- =EDATE(A1, 2*12+4) + 9
- =A1 + 2*365 + 4*30 + 9

Surprisingly, * each formula gives a different result! *So which one should you use?

**5**Comments }

## Introduction to Forecasting in Excel 2016 [Charts & Visual Analysis]

*in*Charts and Graphs

One of the coolest features of Excel 2016 is **forecasting. **Today, let’s understand how it works with a sample data set.

Watch below video to understand forecasting in Excel 2016.

Continue »*Here is an interesting problem to start your day.*

Let’s say you work as DNA sequencing engineer at *The Enterprise. *And you just unlocked the sequence that is responsible for all male problems. *The early onset of baldness. *The sequence code is AAAA. And you want to find out how many times this sequence is found in a sample of DNA strings, in the range B6:B19. Essentially you want the above.

So how do you write the formula?

Continue »Okay, this is an extension of the Neither “A” Nor “B” sum problem we discussed few days back.

Imagine you have a table named * mydata* with a few columns and a stop list named

*as shown above.*

**stop.list**How would you calculate,

- Sum of Hours for all activities excluding those in stop list?
- Sum of all
*Regular*hours for activities not in stop list?

So go ahead and post your answers in the comments.

Continue »We know how to use SUMIFS function to answer questions like, **“What is the sum of values for ‘A’?” **But how would you answer questions like,

- What is the sum of values that are neither “A” nor “B”?

We can still use SUMIFS, but it will get awfully long. So let’s turn our attention to other functions in Excel.

Continue »