I am attempting to make a budget calculator and want to import my CC data to compare my actual spending w/estimated spending based on different categories. Briefly, (see attached screen shot), I have the input from my credit card which has location specific data, I have another column with a refined transaction type, and a third and final column with the associated spending category.
I can not figure out how to use the raw transaction data to search for the refined transaction type and associated spending category.
=VLOOKUP(FIND(C2&"*",Sheet3!A:A,1),A1:B10,2,TRUE)
Problem Example
First of all, the FIND function returns a number, which then becomes a parameter for VLOOKUP. This won't get you the results you're expecting. It'll search for a number.
This is going to be complex but here's a start, for EXACTLY the data you've provided.
=VLOOKUP(LEFT(C2,FIND("#",SUBSTITUTE(C2," ","#",(LEN(C2)-LEN(SUBSTITUTE(C2," ","")))/LEN(" ")))-1),A:B,2,0)
Drop that into cell D2. Have fun.
Related
Like the title says, I'm trying to sum elapsed time based on two criteria in Excel (2016). Specifically the elapsed time of a phone call based on user and call type, examples below.
The actual data is similar to this Dummy Data Set where there would be a list of users, Full name, the duration of a given call, Duration, and the type of call, Call Type.
The expected output would be in this format; however, the main focus for my issue falls under the Total Time column, and its worth noting that the red times shown were hand-done as these are the cause of this post.
As for the logic I'm using at the moment to try and get these results, it's =SUMIFS(C2:C16, B2:B16, G2, D2:D16, H2&"*") where C2"C16 is the Duration column, B2:B16 is the Full Name column, G2 is "Generic User", D2:D16 is Call Type, and H2&"" comes to Local, worth a note is the wildcard, as there are two types of Internal and Local calls, but I'm just trying to get all Local and all Internal without distinction of sub-types.
Additional notes for the cell formats are that the Duration and Total Time columns are set for [h]:mm:ss, but I've also tried other time and number formats which didn't change the outcome.
So at this point I'm just spinning my wheels as I've Googled and looked into different ways to go about this, such as different cell formats, cell operations/logic and so on, and I'm just unsure where the issue may actually be, so any suggestions or help would be very appreciated.
Edit 1: Including a link for the file
J2 This is for your reference only.
=SUMPRODUCT((B$2:B$16=G$2)*(C$2:C$16)*ISNUMBER(FIND(H2,D$2:D$16)))
I'm trying to rank some data in spotfire, and I'm having a bit of trouble writing a formula to calculate it. Here's a breakdown of what I am working with.
Group: the test group
SNP: what SNP I am looking at
Count: how many counts I get for the specific SNP
What I'd like to do is rank the average # of counts that are present for each SNP, within the group. Thus, I could then see, within a group, which SNP ranks #1, #2, etc.
Thanks!
TL;DR Disclaimer: You can do this, though if you are changing your cross table frequently, it may become a giant hassle. Make sure to double-check that logic is what you'd expect after any modification. Proceed with caution.
The basis of the Custom Expression you seem to be looking for is as follows:
Max(DenseRank(Count() OVER (Intersect([Group],[SNP])),"desc",[Group]))
This gives the total count of rows instead of the average; I was uncertain if "Count" was supposed to be a column or not. If you really do want to turn it into an average, make sure to adjust accordingly.
If all you have is the Group and the SNP nested on the left, you're done and good to go.
First issue, when you want to filter it down, it gives you the dense rank of only those in the filtered set. In some cases this is good, and what you're looking for; in others, it isn't. If you want it to hold fast to its value, regardless of filtering, you can use the same logic, but throw it in a Calculated column, instead of in the custom expression. Then, in your CrossTable Aggregation, get the max of the Calculated Column value.
Calculated Column:
DenseRank(Count() OVER (Intersect([Group],[SNP])),"desc",[Group])
Second Issue: You want to pivot by something other than Group and SNP. Perhaps, for example, by date? If you throw the Date across the top, it's going to show the same numbers for every month -- the overall numbers. This is not particularly helpful.
To a certain extent, Spotfire's Custom Expressions can handle this modification. If you switch between using a single column, you could use the following:
Max(DenseRank(Count() OVER (Intersect([${Axis.Columns.ShortDisplayName}],[Group],[SNP])),"desc",[Group],[${Axis.Columns.ShortDisplayName}]))
That would automatically pull in the column from the top, and show you the ranking for each individual process date.
However, if you start nesting, using hierarchies, renaming your columns, or having multiple aggregations and throwing (Column Names) across the top, you're going to start having to pay a great deal to your custom expression. You'll need to do some form of string replacement around the Axis.Column, or use expression instead of Short Names, and get rid of Nests, etc.
Any layer of complexity will require this sort of analysis, so if your end-users have access to modify the pivot table... honestly, I probably wouldn't give them this column.
Third Issue: I don't know if this is an issue, exactly, but you said "Average Counts" -- Average per day? Per Month? When averaging, you will need to decide if, for example, a month is the total number of days in month or the number of days that particular payor had data. However you decide to aggregate it, make sure you're doing it on the right level.
For the record, I liked the premise of this question; it's something I'd thought would be useful before, but never took the time to try to implement, since sorting a column or limiting a table to only show the top 10 values is much simpler
Hello i'm having problems with getting this to work. What i'm trying to do is when you insert a set of measurements i want excel to show the ( In this case products) which are closest to those measurements.
here is a picture:
The result i'm trying to reach is when you type in the measurements you get product(s) and the manufacturer which are closest to those measurements.
Any help is greatly appreciated.
In essence, what you are after is an index+match function. It will allow you to find a value in one list, given a corresponding variable. In this case, given a measurement, it will find a manufacturer and product combo in your list.
Your problem is that you will need to adapt your data to allow for this. For example, you need to decide whether you only want the closest match for measurements or if you need the closest match that is greater than the measurement you provide.
It is also possible that you'll need to split your measurement column into two different columns (unless all you need is the total area irrespective of individual lengths).
You could potentially avoid the index+match by using conditional formatting, but that would still require the data manipulation.
Given the information you provided, the answer will never be much more informative than this. But this should get you started and the following steps can be made easier with help from google.
I am using Really Simple Traffic Logger to store Date, Timestamp, IP and visited site by users on my website. Each user visiting the website is assigned a UID by a parameter in the URL in the form of:
http://www.domain.com/site.php?=dTM_c1_uid7
dTM = customer,
c1 = category 1,
uid7 = uid for person 7
The csv file stored contains the following:
"DATE","TIME","IP","LOOKING_FOR"
"2016-05-22","07:30:40","XX.XX.XX.XX","/site.php?=dTM_c1_uid7"
"2016-05-22","07:31:10","XX.XX.XX.XX","/site.php?=dTM_c1_uid7"
"2016-05-22","07:31:19","XX.XX.XX.XX","/site.php?=dTM_c1_uid8"
the information is stored in a CSV-file, where I am attempting to sum the results of the data, which is to be visualized by another script in real-time. However, as many of the visitors are the same people visiting the website more than once, I would like to remove these based on the UID parameter in the URL, before calculating the sum, so each count (hit) can be calculated as unique hits.
I am therefore trying to work out a formula for auto-removing duplicates that contains the "_uid7" parameter, before calculating the sum.
Is there a smart method for constructing a formula in excel that can do that automatically?
Thank you.
Supposing your data starts from A1 Please post the following formula in B1and fill down the column B with data in column A
=TRIM(SUBSTITUTE(MID(A1,(SEARCH("dTM_c1_",A1,1)+7),99),CHAR(34),REPT(CHAR(32),99)))
You will get uid7, uid8 etc which can be counted or other processing can be done.
EDIT
Based on your comments and taking "dTM_c1_uidnn.." string counts of occurrence is shown in the following snapshots. I have shown two snap shots out of which one hides the helper column.
This is the best I could do at the moment. Column B can be filtered either with Excel native Remove Duplicates OR by a VBA routine. Finding unique values of numerical values is comparatively easy using Frequency Function But somehow after repeated attempts despite following some tutorials, I could not get the desired results for text strings. I would appreciate your feedback positive or negative. My efforts would continue to find the most optimal solution.
I'm not even sure how to ask this.
I have a database, where each row is a person. Columns are contact info, phone, etc. One column is 'date visited'. There can be multiple dates visited for each person. I don't want to use a comma or stack them all in one field.
Is there a way to have a 'nested' list (not a drop-down menu - just a list of visited dates for each person), such that one person still only consumes one single row?
Yes,
To accomplish this give each person an ID that is unique and won't change.
Then on a separate sheet, store the ID and date.
main sheet ( ID, Name, Contact Info, phone, ect)
second sheet ( ID, date visited)
In database theory this is called a 'one to many' relationship, and what i'm describing is called 'normalizing your dataset'.
In Excel you can now use formulas to manipulate the data however you need to or can imagine after you split this apart.
As you mentioned in comment, counting all visited dates for a user.
On the main sheet to the right you could use:
=countif(Sheet2!A:A,Sheet1!A1)
This would Count all of the ID's in the second sheet that match the current row's ID on your main sheet.
Notes about using one cell:
Storing all the dates in one cell will eventually max it out, and will make it hard ot view/search as it grows so i highly advise against this approach.
If however you insist on keeping the dates in there, you could count the visits by counting the total number of comma's + 1 liek this =(LEN(G1) - LEN(SUBSTITUTE(G1,",","")))+1 This formula takes the length of all the dates, and the length of dates with commas removed and subtracts them to get a number of occurrences.
Notes about using multiple columns:
This approach has the same idea as the one I suggested, where we are associating a number of dates with the row's identity of a person. However, there are a few key limitations and drawbacks.
The main difference is that when we abstract the dates by transposing them to extend vertically we can manipulate them easier, and make a list of 20 dates for one person much easier to read. By transposing the dates vertically in the second sheet instead of using this approach we also gain the ability to use Excel's built in filter. Just storing large amounts of data is useless by itself. While storing it in a way that you can view and manipulate easy makes everything much more powerful.