How to create a table with data with computations - python-3.x

I did an experiment, where I recorded two columns of data (column A and column B). However my experiment needs calculated data. My goal is to create a data frame myself (as you do in excel), but I want to incorporate the formulas I need to get the calculated values for my data.
Note: I'm NOT using an existing data frame. I want to create my own data using arrays. Exactly as you do in excel, you put the values in a table and then plot it.
For example:
Column A Column B Column C
1 1.1 Column A*constant
Should I create functions for each formula I need? But still I don't know how to incorporate these functions in the arrays.
I'm trying to do literally what you do in excel (create a table with values and incorporate the formula in each cell), but I'm not sure what will be the easiest way to do this for a beginner in Python.
pd im using jupyter notebooks for this with python 3

Related

Is there a way I can change a cell that holds data into a table using functions?

When converting data from PDF's into excel I have run into an issue where instead of giving me the table in a table format, it comes out in a single cell separated by spaces. I have been dealing with this issue for a while.
Here is an example of what the PDF converter will give me
The data in the left and right column are Identical in this case, but this is not the norm.
I have tried a few things. My first formula returns a single column of data, but each cell in the column has two data points.
=TRANSPOSE(TEXTSPLIT(D2,CHAR(10),,TRUE))
My second returns a single column of data, but only the first desired column.
=TEXTSPLIT(TRANSPOSE(TEXTSPLIT(D2,CHAR(10),"##0.00")),CHAR(32))
How do I turn this into a 2 column table with a formula?

Using IF with AGGREGATE

While I am a longtime 'lurker' and have gleaned a great amount of Excel knowledge through this site, I've never asked a question before. This time I'm really stumped...
I have a table with multiple columns. The data I'm working with is obtained from a multiple VLOOKUPs of another workbook for which I do not own. That workbook has some issues with hidden characters and rows that are hidden. I'm trying to create a dashboard from this data and was successful using the AGGREGATE function (2,7) to COUNT and omit the data I don't want.
The next tier for this data needs to incorporate a lookup against another column (image attached). For this, I want to look up data in column B and subtract cells in column C if the data in column B matches a cell in column A.
I have tried multiple ways of doing this but I think that AGGREGATE might be the best approach since it can ignore hidden data and rows.
My latest attempt was to add an IF statement as follows, but that results in a SPILL condition:
=IF('Transport Calendar'!E2:E830='Transport Calcs'!M6,AGGREGATE(2,7,'Transport Calendar'!X2:X830)-AGGREGATE(2,7,'Transport Calendar'!Z2:Z830),"FALSE")
Any help would most certainly be appreciated!

Making a dynamic column line graph

I am trying to create a graph where the number of columns varies. what I have done is used name manager to label each of the possible columns (1-100). I have then used these named ranges to create a graph.
Each column in the table should be identified as a series, the issue is that I do not know how to change the number of series automatically, so that when data is added to the column the chart automatically added the series in. I tried to do this by naming the range as a table, this also did not work as it included the empty columns as series on the chart.
the data I am trying to use is as follows;
When I add data to another column I want to add that series to the graph. Is there a way of doing this? because all I have been able to find are examples where the number of rows are the only thing that is dynamic.

Transfer values from one table to another in MS Excel by matching values in one row to values in a column

I am trying to transfer the values in columns p1 through p7 from Table 1 into Table 2. I want to do this by comparing the values in columns A, B, C, and D in Table 1 to the values in column X in Table 2 which are all strings. My data set is much larger so I provided a smaller model below.
Table 1
Table 2
I think I can use the Index and Match functions in Excel to do this based on what is found on ExcelJet website. The only thing I'm having trouble understanding is how to check for multiple values in one row from Table 1 and compare them to each value in column X of Table 2.
Any help would be appreciated.
I would recommend you to use Power Query instead of a formula. I have been using it for a while and it is way better. It is an add-in for Excel 2010+ (by default in Excel 2016 known as Get and Transform). There you can connect directly any source and transform your data easily.
For your case follow this steps:

Excel graph based on data subset

I am struggling with Excel to make a graph based on a condition that is not part of the graph. The data set it is based on can't be filtered. It has to be shown in full, but the graph should only contain a subset based on a fixed criterium. For instance: I have 20 rows of data, but only row 3, 9 and 10 meet the criterium. And this changes all the time. Only those three (in this example) have to show up in the graph. I just don't know how to do this. Any thoughts? I'm working with Excel 2010.
I am not sure which other information is useful for you to understand my problem. Please let me know.
Thanks!
You can use Excel Formulas to filter the data to another place (maybe a hidden Worksheet) and give that one as the source of the chart.
If your data is in a properly formatted table, you could try a pivot chart.
a) It might be helpful if you could provide sample data and sample output you are trying to achieve?
or,
b) you could add a formula column which evaluates the contents of the data column, e.g. if criteria column = "some value" then data else zero or null (E.G. your criteria column is A, your data column is B, then in column C you could write =IF(A2="Yes",B2,0) or =IF(A2>=5,B2,0)). then you can graph the data in column C?

Resources