Questions tagged [analytical]

82 questions
0
votes
1 answer

Consecutive n week calculation

I have a table consisting of 3 columns: Product, Week, Units Sold. I am trying to come up with a table to show the best consecutive 4 week sales. I have tried several different window analytical functions and can’t seem to get what I need. This is…
J..
  • 3
  • 1
0
votes
3 answers

Complex Ranking in SQL (Teradata)

I have a peculiar problem at hand. I need to rank in the following manner: Each ID gets a new rank. rank #1 is assigned to the ID with the lowest date. However, the subsequent dates for that particular ID can be higher but they will get the…
0
votes
1 answer

Why might my SUM query be producing different results each time I run it?

It's probably pointless posting this as I can't show the actual code causing the problem, and due to not knowing the source of the issue have not been able to recreate it using fake data, but wanted to ask in case anyone has seen something…
0
votes
1 answer

Percentage of cases they will contradict where atleast one of them is correct

Braden and Fred are two independent journalists. Braden is usually correct in 33% of his reports and Fred in 70% of his reports. In what percentage of cases are they likely to contradict each other, talking about the same incident where at least one…
0
votes
1 answer

conditional count of items row wise in SQL Oracle

I posted similar question conditional count in a list of strings in SQL Oracle this time the dataset is row wise but the logic remains the same. the items will be added to list1,2,3.. one by one. I used date when an item was added to the list. here…
Pato
  • 153
  • 6
0
votes
1 answer

Comparing analytical and empirical moments of pareto distribution

Below I used the nympy generated draws to compare the empirical moments of Pareto distribution with analytical ones (I used the following link for the formulas of mean, variance, skewness and excess kurtosis,…
0
votes
0 answers

SQL to UNION history table with current table (with date range aligned)

Hi i have below 2 tables table_histroy version, from_date to_date ID Place 1 1900-01-01 00:00:00 2020-07-08 10:00:49 123 Delhi 2 2020-07-08 10:00:49 2199-12-31 23:59:59 123 …
0
votes
3 answers

Datawarehouse for analytical CRM

Is it beneficial to pull the data from Datawarehouse for analytical CRM application or it should be pulled from the source systems without the need of Datawarehouse??....Please help me answering.....
0
votes
1 answer

Teradata Get MTD Unique Users for each day (ex. on 12th Mar I need to have 1st to 12th unique users. similarly for each date for last one year

I need to get MTD Unique users count each day for last 1 year. Ex. if my data is like dt customername 1 a 1 b 2 a 2 c 3 b 3 a 4 c 4 d 4 e expected output- on 1st only 2 unique user. on 2nd (1&2nd) 3 users. on 3rd (1st to 3rd) 3…
Ganesh
  • 7
  • 4
0
votes
0 answers

Row_number function with OR condition in RDBMS

I have a table with below data. In which I want to assign unique id to combination of two columns(emailid and collegeid) with or condition. In the case of emp "1" and emp "2" has the same emailid but different collegeid still they are linked to each…
Nishant Gupta
  • 21
  • 1
  • 6
0
votes
0 answers

Why sqrt(1-4*pow(X,2)) is showing math domain error, when X is less than 0.5?

I tried to implement Hertz distribution load on a soil domain. The expression is sqrt(1-4*pow(X,2)) where X is less than 0.5. I get math domain error when i try in analytical field using expressions in ABAQUS. How to solve this problem.
0
votes
1 answer

Find the area and the volume of the tetrahedron

So given ABCD, A(0,0,0) B(1,1,0) , C(1,-1,1) ,D, (3,0,1) I need to find the volume of the tetrahedron now I know that the volume of the tetrahedron = 1/6 detA But the determinat of this matrix is 0 so that's it I have the volume = 0 or I didn't…
0
votes
2 answers

Retrieve data from data lake to analytical system

We have created a new data lake in Hadoop file system. Data is stored in the form of ORC. Currently analytical system is directly connecting to data lake to read these ORC file. Is there any way to create a middle layer between data lake and…
0
votes
0 answers

Cohort analysis : index a row on a entire column

i'm a newbie in Pandas. I'm actually struggling with Cohort analysis. I have : Cohort_Group Cohort_period 2015-06 2015-06 1 2015-07 2015-07 2 2015-08 2015-08 2 2015-09 2015-09 1 2015-10 …
jeremie
  • 9
  • 1
0
votes
1 answer

oracle's analytical function issue

Please let me know if the following is off topic, or not clear, or too specific, or too complex to understand. I think the following is a challenge to describe, understand and solve. CIF=cost, insurance, frieght (basically it is the import…