How to automate the seasonal adjustment using X12 Arima - gretl

I am very new on Gretl and I need to do the seasonal adjustment of the same time serie every week. Currently, I am doing it manually, so I would like to know if there is any code that I could write in order to automate this process, importing the file from excel and doing the X12 arima for variables on columns B,C and D. I would appreciate your help. Thank you

Please, try this:
open "C:/your_file.xlsx"
series x1_sa = deseas(x1)
series x2_sa = deseas(x2)
series x3_sa = deseas(x3)
Where x1, x2 and x3 are the names of your variables.

Related

Creating tables for clean Data

let me start out by saying I have a basic understanding of python and excel. What I’m trying to do is take a CSV file with data points for voltages along side with date in mm/dd/yyyy in a separate column, and averaging the data points for each day into a chart. There’s roughly 10000 data points for the month each separated by 5 minute increments. I don’t know where to start. I also have to do this about 12 separate times so if I can just feed a program an excel file or data from notepad that would help me tremendously.
I’m a bit rusty with python but I can read it pretty well to figure out what does what. Any help would be greatly appreciated.
If I can do this all in excel then that would be amazing. But I would like to brush up on my coding. If someone can point me in the right direction, I’m using Jupyter notebook and excel for reference. I tried starting with just opening the file with open() but now I don’t even know where to begin. Should I install pandas? Selenium?
I tried grouping the data in excel manually by using group. I tried opening up files in Python and creating a list of values to go through and average them. I also looked into using pivot tables to group the data as well.
No coding needed for that. Excel pivot can solve it.
Bring your date column in a format excel understands as date.
Insert pivot from the range that contains your data
Drag the Date to lower left quadrant rows
Drag the voltage to lower right quadrant values
Change aggregation of values from sum to average
The result will be this table:

Excel - Sum of data at equal intervals

I have some time series longitude latitude data which I am trying to sum up for each month. ( 4 x column headings Time, long, lat, precipitation).
Is there a way of summing data automatically for regular intervals or do I have to manually update the sum equation code cell?
Any help would be hugely appreciated.
Many thanks
I have tried summing it manually but due to large data mass this will take along time.
You can very easily find the month number of a date, using the =Month() worksheet function. Adding such a column might give you the possibility to use the basic "Subtotals" feature of Excel, as you can see in this screenshot:

Trying to plot a set of forecasted values to the end of my actual values in excel but can't get the dates to line up

I have a simple line chart in excel. The first series has values that were given from 1/2016 monthly all the way up until 12/1/2019. I was asked to predict the next 12 months and then plot those new predictions on the same chart as the given values.
This is what my chart looks like. I've started with all the dates as the X and the given values up until the end of 2019 as 1 series and then I just tried to add the second series which is just the dates and values for 2020 but for whatever reason, excel things those are happening at the start of 2016. Or maybe it's just using 2 different x axis?
Edit: Tables

Excel sheet data in Excel dashboard grouping by one column as x axis and sum of other column as y axis

I am trying my hand on the excel dashboards for the first time.
I have some data in one sheet like below:
Story Assignee StoryPoint
XYZ Amit 3
sdg Sumit 4
tghgj Shweta 2
fgjhd Amit 3
gfhfhj Shweta 2
In the second sheet i am trying to depict this data in the chart with my X-Axis has assignees and Y axis has sum of the story points.
Can someone guide me on how can i achieve that?
I just want to have the idea on what all can i implement and the rest i can explore.
You could try Pivot Chart.
example below could be helpful
https://www.excel-easy.com/examples/pivot-chart.html

Excel Timeseries Forecasting with Seasonality

I am trying to create a forecast using a monthly timeseries data set of marketing expenses for a fictional company. The data looks something like this:
Using linear regression to forecast future sales, I get the following result:
My problem lies with the seasonality of the marketing expenses (higher in the summer months for instance). I would ideally like to calculate to forecasted values of future months including seasonality. I read somewhere about ARIMA forecasting, but am really searching for some best ideas on how to accomplish the task.
To be clear, I do not JUST want a chart and trendline, but the data to support it too.
Any help would be much appreciated!
You can do that easily using Excel (2016) Forecast tool by first selecting your data, then clicking on:
Data -> Forecast Sheet -> Options -> Set Manually (under Seasonality)
You can also play with the options. Once you click on "Create", Excel will generate a graph, and a table with relevant data.
Alternatively, you can also create a binary variable for each season, and calculate a multiple regression for the Marketing expenses controlling for time, and each of the binary variables for the seasons but one (which is the reference group). You could either use excel analytical tool, or any other statistical software.

Resources