Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
ffm-baseline
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ML
ffm-baseline
Commits
26adcdf9
Commit
26adcdf9
authored
Dec 18, 2018
by
王志伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
统计日记本点击的各个来源数量
parent
246e3a1c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
0 deletions
+20
-0
temp_analysis.scala
eda/feededa/src/main/scala/com/gmei/temp_analysis.scala
+20
-0
No files found.
eda/feededa/src/main/scala/com/gmei/temp_analysis.scala
View file @
26adcdf9
...
...
@@ -116,6 +116,24 @@ object temp_analysis {
)
final_id
.
createOrReplaceTempView
(
"final_id"
)
val
diary_clk_all
=
sc
.
sql
(
s
"""
|select ov.partition_date,count(ov.cl_id) as clk_num,count(distinct(ov.cl_id)),count(ov.cl_id)/count(distinct(ov.cl_id))
|from online.tl_hdfs_maidian_view ov left join final_id
|on ov.cl_id = final_id.device_id
|where ov.action = "page_view"
|and params['page_name']="diary_detail"
|and ov.cl_id != "NULL"
|and ov.partition_date >='20181201'
|and final_id.device_id is null
|group by ov.partition_date
|order by ov.partition_date
"""
.
stripMargin
)
diary_clk_all
.
show
(
80
)
//日记本点击
val
referrer
=
List
(
"about_me_message_list"
,
"all_case_service_comment"
,
"all_cases"
,
"diary_detail"
,
"diary_list"
,
"diary_listof_related_service"
,
"answer_detail"
,
"community_home"
,
"conversation_detail"
,
"create_diary_title"
,
"diary_listof_related_service"
,
...
...
@@ -144,6 +162,8 @@ object temp_analysis {
}
//5.登录人数
val
log_device_temp
=
sc
.
sql
(
s
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment