SO I'm trying to build a growth at a reasonable price screener, given a list of all stocks on the NYSE, that reads in and fills my column A with the ticker and B with the company name. The next columns use the SMF add-in from Yahoo and pulls data, such as the P/E and other metrics, off GARP (GROWTH at Reasonable price.) The formulas were built in the first row and dragged down over the rows of stocks. The issue that I am having is the formulas preform their job for the fist hundred or so stocks (rows), and then they all return error. However, if I scroll to a Blue chip stock and, in the formula box, click and press enter, the desired value will replace the error result.
Online I have found forms that suggest using arrays yet I cant seem to get an array to work, assuming my syntax would be =smfGetElementNumber(A4:A3298,#), where 'number' references a predefined function in the smf plugin and the data range is the spread of stock tickers.
Please advise as to why I receive this issue and what I can do to fix it.
Couple things you can try:
Make sure , Formulas->Calculation Options->Automatic is checked
Check the references of the cells in your formula i.e Relative vs Absolute referencing
Edit:
If You have Calculation Options set to Manual and update the dependent cells follow this hack
Select the cells that have issues and Select Data->Text to Columns->Finish
Related
I have created an excel sheet to have an overview over costs in my projects, however, I also need an overview of costs per category in my projects. I googled it and tried to find examples online, however, it only returns a value of 0, which shouldn't be the case. Can anyone help me? The sheet looks like below.
I am going by the SUMIF function to group by category but my excel sheet is a bit more complex than that so I tried to adjust it accordingly as seen in the code below. No matter what I do it either returns an error or 0.
=IF(B12=B8;"";SUMIF(B12:B39;B12;J12:BE39))
In the formula above I am trying to sum the costs of a category that could be written in B12, for example, Software development. For confidential reasons, I cannot show the actual filled out excel sheet.
sumif does not work with summing multiple columns. Instead use a sumproduct statement instead like so:
=IF($B12=$B$8;"";SUMPRODUCT(($B$12:$B$39=$B12)*($J$12:$BE$39)))
A detailed explanation to how this works can be found here
Edit:
I sense a follow up question coming, how to skip certain columns. Because as you have set it up now, it will count the entire range from J12 to BE39, in which you have both forecast costs and actual costs. I guess this is to compare the costs to what was projected and what the actual costs are. Right now it will count both the projected and actual cost, doubling up. To prevent this you can enter every second column separated by a + like so:
=IF($B12=$B$8;"";SUMPRODUCT(($B$12:$B$39=$B12)*($J$12:$J$39+$L$12:$L$39+$N$12:$N$39)))
Also I have added $ signs to all non-changing values so it will work when dragging down the fill handle on the formula to populate the below cells.
I use the auto-fill handle very often; both dragging and double-clicking. I need it, so I don't want to disable it in the options. However, I have certain situations where I'm just trying to copy down values to the next cells, and it appears Excel is using some type of memory/cache to auto-fill them with crazy values. I recognize the values; but there is no rhyme or reason as to why it's auto-filling them at this moment in time.
Example: There are no formulas in any of these cells and this is just a brand new sheet in Excel. I want to grab handle of cell B10 and copy it down to B14:
Now, I wish I could record a little clip of me copying this down so you can see it change the values live, but I promise you, this is what the values get changed to, and it has no relation to the values above it in the same column or anywhere in this sheet and there are zero formulas anywhere; just a simple table being populated:
What can I do to get this to copy the correct values? This has created errors in other tables where I didn't catch it populating the cells incorrectly in time.
My colleague has been suffering this exact problem and his solution is detailed below:
Go into Advanced Options and under General click on Edit Custom Lists button and you should find your values listed there. If so, you can delete them from this list and the problem should go away
Good luck!
I have a the following table, it has more columns and is 40 rows long
but this is an example of the data. The table is sorted by Team #
Data Table
I am trying to create a 2nd table that shows the top 10 teams that
delivered gears. I want to do this for the other columns as well.
I am trying to do this without VBA.
I used this function and it worked well:
=INDEX(TT_Team,MATCH(LARGE(TT_Tele_Gears,$A3),TT_Tele_Gears,0))
The problem is the duplicate data for the amount of gears delivered
IF two teams have delivered the same number of gears I want to show
them both, but do not care about which is #1 or #2
Currently I get this:
Top 10 Table
Any ideas on a fix ?
Thanks in Advance
You could try a solution like this:
The formula in F2 copied down is just:
=LARGE(B$2:B$12,D2)
and in E2 as shown it's this:
=INDEX(A$2:A$12,LARGE(IF(B$2:B$12=F2,ROW(B$2:B$12)-ROW(B$2)+1),COUNTIF(F2:F$6,F2)))
confirm with CTRL+SHIFT+ENTER and copy down
It's the COUNTIF part at the end that makes the difference. This is counting from the current row, so for duplicates as you go down the column the COUNTIF value changes, so you get each duplicate
I have a pretty extensive spreadsheet that stores data over many years, and to help culminate that data I have a had to make multiple summary pages to calculate the data one for each year. I want to instead make a single sheet that will summarize the data and the user can simple select the year they want to view from a drop down menu and all the formulas will automatically calculate the new data. From what I can tell this can be done by using the "indirect" function but I cannot get it to work and am starting to think that function will not work because of the way the formula works. Does anyone have a working method that will generate the desired results.
Manual Formula
=SUMPRODUCT((MONTH('W.A.R. 2016'!$A4:$A369)>=1)*(MONTH('W.A.R. 2016'!$A4:$A369)<=3)*('W.A.R. 2016'!$A4:$A369<=TODAY())*(ISNUMBER(FIND("Work",'W.A.R. 2016'!B4:B369))+(ISNUMBER(FIND("Wrk/Lve",'W.A.R. 2016'!B4:B369))/2)))
Formula im working on.
=SUMPRODUCT((MONTH(INDIRECT("'("&O2&")'!$A4:$A369"))>=1)*(MONTH(INDIRECT("'("&O2&")'!$A4:$A369"))<=3)*(INDIRECT("'("&O2&")'!$A4:$A369")<=TODAY())*(ISNUMBER(FIND("Work",INDIRECT("'("&O2&")'!$A4:$A369")))+(ISNUMBER(FIND("Wrk/Lve",INDIRECT("'("&O2&")'!$A4:$A369")))/2)))
In theory I cannot see why its not working but I think it the way indirect pulls the data.
I can spot a couple of issues.
This has unnecessary brackets around the sheet name:
INDIRECT("'("&O2&")'!$A4:$A369")
It will produce a string like: '(W.A.R. 2016)'!$A4:$A369
You just want to use:
INDIRECT("'" & O2 & "'!$A4:$A369")
There is some inconsistency in your formulas
The first formula searches for "Work" in B4:B369 and "Wrk/Lve" in B4:B369, whereas the second formula has the ranges swapped around.
The best advice I can give on trying to figure out where a formula is going wrong is using the Evaluate Formula tool.
Select the cell that has the formula, go to the Data tab on the ribbon and click Evaluate Formula. It will pop up a dialog that allow you to step through each part of the formula as it calculates. From there you should be able to see what's going wrong.
My company receives weekly updates from different providers.They all give the same type of data but in a different order ( ex: one company will give column A= Name / column B= Quantity / column C= Cargo. When an other will give column A= Cargo / Column B= Name / Column C = Quantity ) . I think I need to create a Vlookup formula that would automatically find the new data, and replace the old one with it in the right place(if the data changed from last week). I understand that the formula will have to be different with every provider since they all have a different format.
To help you help me, I ll write the order of columns in our Template, followed by the order of one of the providers:
Our template
A:Reference Number
B:IMO
C:Vessel Name
D:Commodity
E:Product detail
F:Quantity
G:Departure country
H:Departure port
I:ETA
J:ETB
K:ETD
L:Current status
M:Destination Continent
N:Destination Country
O:Destination Port
P:Charterer
Q:receiver
Providers Template:
B:Vessel name
C:ETA
D:ETB
E:ETD
F:Departure Country
G:Departure port
H:Destination Continent
I:Destination Country
J:Destination Port
K:Commodity
L:Product detail
M:Quantity
N:Name of vessel
O:IMO
P:Reference code
Q:Charterer
R:Current status.
Any idea how to do this???
Okay based on your last response, I'm going to provide a potential solution with some caveats and assumptions.
Caveats
A VBA solution may be best here if the data is coming in from multiple source workbooks. However if this happens infrequently it wouldn't save you much time to do a VBA solution. Also if you are unfamiliar with VBA I don't recommend you simply paste in someone else's code that you got online - because it could be malicious, or it could lead you to be unable to actually do your job if some problem with the code arises that you can't fix.
Assumptions
-I'm going to assume that each vendor is included in the same workbook, on its own tab.
-I'm also assuming that the data is going to be somewhat consistent, as you noted in the comments to your question above.
-For now, I'm assuming that you only need a few fields from each vendor, and that those fields are always the same between vendors. This is not necessarily required to use this method, but it simplifies things a bit and will get you start. For now, let's assume you only care about the Vendor name, the cargo type, the quantity, and the expected shipping date.
Proposed Workflow
My general advice for someone doing a 'mini-database' in Excel like this is to keep separate tabs for their data dumps, their working formula sheets, and their summary tabs used for display/printing purposes. Keep your coding solutions only to the level that you yourself understand, and don't throw away the raw sourcebooks. Ideally if someone is reviewing / auditing your work they should be able to simply copy & paste in a random data sample and immediately see if it is picking up the right amounts.
So, My proposal would be to have a single summary tab, a data-dump tab for each vendor (also called a "landing page"), and an intermediary formula tab for each vendor.
The data dump tabs should contain the data exactly as it comes in from the vendor, without adjustments. Formatting your data-dump tab to match your raw data (rather than formatting your raw data to match your data dump tab) will mean that each time you update it, minimal intervention will be required. This is thus 1 step short of full 'automation'.
The intermediary formula tabs for each supplier should be in the same format as each other intermediary formula tab. This will allow for easier pickup on the main summary tab. The purpose of the intermediary formula tabs will be to give you an opportunity to look at that vendor's excel datadump, and determine the best way to pull the fields that you care about for review.
The summary tab will simply be a list of all vendor tabs, showing a grid of the fields that you care about from each.
Steps to complete
Using the "providers template" that you have in your question, dump that tab into "Provider A data-dump" tab.
In the "Provider A Formulas" tab, we will first type the provider's name as the sheet name. In cell A1, type "Index". In cell B1, type "Reference #". In cell C1, type "Cargo Type". In cell D1, type "Quantity". In cell E1 type "Shipping Date".
Column A will hold an index equal to the number of orders being shipped from that vendor. The formula in A2 will be "=1", and the formula in A3, and copied down, will be:
=if(row()<=count('Provider A Data'!M:M),row()-1,"")
This will count which row you're on, and if the row you're on is less than the total rows with numbers in the quantity field of the raw data tab, it will show that row number (-1 for the header). Otherwise, it will show a blank.
For the rest of it, if your data is truly consistent, then you can simply set the first cell in row 2 to be equal to a specific cell in the other tab. ie: B2, which shows the reference ID, could be simply:
='Provider A Data'!P2
Then just drag that down and it will pick it up as you drag. You will use your index key in column A to make sure you have dragged far enough.
There are formula solutions (like vlookup) which could be used to find a specific reference ID in the raw data tab and pull the exact row from another column, but you don't need to use those if you are simply keeping things in the same row-order as they appear in the data dump tab.
Then for your summary tab, simply create some columns that pull in amounts from each vendor. Once you have set up the workbook for the first time, all you'll need to do to update will be drag down rows in the formula tab. If you have further specific questions about how to achieve any of this, please ask in a specific question, noting what you have tried to do, and what part of that has failed.
I hope this helps you get started.