Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

missing bars from the bar chart

Hello,

I need help...

I tried to create a bar chart with 7 age groups, but the bar chart only show 3 age groups, what went wrong?

Users:
LOAD UserID,
Gender,
Age,
if(Age>0 and Age<=18,'Under 18',
if(Age>18 and Age<=24,'18-24',
if(Age>24 and Age<=34,'25-34',
if(Age>35 and Age<=44,'35-44',
if(Age>45 and Age<=49,'45-49',    
if(Age>50 and Age<=55,'50-55','56+')))))) as [Age Group],
Occupation,
ZipCode
FROM
[$(vFilePath)\users.xlsx]
(
ooxml, embedded labels, table is users);

5 Replies
vishsaggi
Champion III
Champion III

Does your bar garph has age groups 35 to 55? Can you share this sample to look into?

antoniotiman
Master III
Master III

Hi Wee,

may be

if(Age>0 and Age<=18,'Under 18',
if(Age>18 and Age<=24,'18-24',
if(Age>24 and Age<=34,'25-34',
if(Age>34 and Age<=44,'35-44',
if(Age>44 and Age<=49,'45-49',    
if(Age>49 and Age<=55,'50-55','56+')))))) as [Age Group],
Regards,

Antonio

prma7799
Master III
Master III

Please share some sample app with data

Not applicable
Author

Hello everyone,

Thanks for your replies.

My freind has resolved the problem. Many thanks and appreciate all your valueable inputs.

Regards,

Wee 

jmvilaplanap
Specialist
Specialist

Hi

To recode like this, I think is easy to don't have gaps in between years:

LOAD

  UserID,

  Gender,

  Age,

  if(Age<=18,'Under 18',

  if(Age<=24,'18-24',

  if(Age<=34,'25-34',

  if(Age<=44,'35-44',

  if(Age<=49,'45-49',

  if(Age<=55,'50-55','56+')))))) as [Age Group],

  Occupation,

  ZipCode

FROM

[$(vFilePath)\users.xlsx]

(ooxml, embedded labels, table is users);

And if you have gaps, maybe you don't have data for those intervals.

Regards