• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Junilu Lacar
  • Martin Vashko
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Scott Selikoff
  • salvin francis
  • Piet Souris

?Solve this question in eclipse or spark-shell command prompt using Scala?

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I have a sample data set of water level in the format given below. I have to predict the future water level by analyzing this data set.

Date,POONDI,CHOLAVARAM,REDHILLS,CHEMBARAMBAKKAM
01-03-2019,477,48,520,22
02-03-2019,478,48,513,21
03-03-2019,475,48,506,20
04-03-2019,472,48,499,19
05-03-2019,469,48,492,18
06-03-2019,466,47,485,18
07-03-2019,462,47,477,18
08-03-2019,458,47,470,18
09-03-2019,453,47,463,17
10-03-2019,448,47,456,17
11-03-2019,443,47,449,17
12-03-2019,439,47,442,17
13-03-2019,433,47,435,16
14-03-2019,429,47,428,16
15-03-2019,424,47,420,15
16-03-2019,420,47,413,15
17-03-2019,415,47,406,15
18-03-2019,411,47,399,14
19-03-2019,406,47,392,14
20-03-2019,406,47,392,14
21-03-2019,396,47,377,13
22-03-2019,391,47,370,13
23-03-2019,386,47,363,13
The output should be like the user should pass the date (date in future) as input and the system should give the water level during that date..This should be solved in spark-shell or eclipse using scala. Please help me
 
Marshal
Posts: 66635
251
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch

We don't give out complete answers; please show us what you have got so far, and explain how you are going to solve this problem.
 
Bartender
Posts: 3673
151
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you familiar with linear regression? I woud start by doing a linear regression between the left column and the following column, since the waterlevels (if that is what the second column is) are clearly dependent on the date. Now, either you look for a library that can handle such regressions (I know that Apache has a dedicated library), search the internet for appropriate formulas, or you can use my Matrix class, that has an in-built linear regression. Matrix.java
 
It's hard to fight evil. The little things, like a nice sandwich, really helps. Right tiny ad?
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!