안녕하세요,
나는 프로 JMP가 아닌 표준 JMP를 사용하고 있습니다 ...
그리고 차세대 제품 카테고리 모델을 만들고 싶습니다. 예를 들어 고객이 제품 카테고리 A를 구입 한 경우 구매 가능성이 높은 다음 제품은 JMP 버전에서 사용할 수 있습니까? 나는 6 가지 제품 카테고리 만 갖고 있으므로 Market Basket Analysis와 같은 것은 아닙니다.
귀하의 도움은 매우 시급하므로 훨씬 더 높이 평가 될 것입니다.
정말 고맙습니다
고맙습니다
데이터는 어떻게 생겼습니까? 고객별로 "바구니"가 있습니까?
가능한 간단한 해결책은 각 바구니를 데이터 행으로 시작할 수 있다고 생각합니다. 그런 다음 각 제품 범주에 대한 표시기 열이 있습니다. 1 = puchased; 0 = 구매하지 않았습니다.
그런 다음 이러한 지표 변수의 다 변수 상관 관계 분석 (Analyze> Multivariate Methods> Multivariate)이 함께 구입 한 제품 카테고리를 알려줍니다.
가장 좋은 방법이 무엇인지, 어쩌면 비상 사태 플랫폼인지는 모르겠지만 여기에 아이디어가 있습니다.
저는 개인화 된 예측을하기 위해 각 고객에 대한 충분한 데이터가 없다고 생각합니다. 따라서이 아이디어는 모든 고객이 추측 할 수있는 데이터를 사용합니다. 나는 일련의 구매로 다음과 같이 합성 된 데이터 테이블을 만들었다.
고객 구매 데이터
다음과 같이 제안합니다.
마지막 구매 : 1 다음 구매 제안 : 2
마지막 구매 : 2 다음 구매 제안 : 3
마지막 구매 : 3 다음 구매 제안 : 4
마지막 구매 : 4 다음 구매 제안 : 5
마지막 구매 : 5 다음 구매 제안 : 6
마지막 구매 : 6 다음 구매 제안 : 1
totalProds = 6;
maxPurchases = 10;
totalCustomers = 1000;
_p = 1; // customers buy the next product in the sequence 10% of the time and a random product 90% ...
nextprod = Function( {}, // this is a synthetic model, just to have some data to play with
If( Random Uniform() > .90, // this is a weak relationship
_p = _p + 1;
If( _p > totalProds, _p = 1 );//
, // else
_p = Random Integer( 1, totalProds )
);
Return( _p );
);
// customers have up to maxPurchases, represented as a list of product numbers (starting at 1)
customerHistory = Function( {},
{result = {}, i},
For( i = Random Uniform( 1, maxPurchases ), i > 0, i -= 1,
Insert Into( result, nextprod() )
);
Return( result ); // {4, 5, 5, 1, 2, 4, 4, 6}
);
// make a customer table with synthetic data
dt = New Table( "Untitled",
Add Rows( totalCustomers ),
New Column( "customer", Character, "Nominal", Formula( Right( Char( 1e9 + Row() ), 8 ) ) ),
New Column( "purchases", Expression, "Nominal", Formula( customerHistory() ) ),
);
dt << runformulas; // make the table formulas ready
dt:customer << deleteformula; // and remove the formulas
dt:purchases << deleteformula; // in case the table needs sorting, etc
// record every pair of purchaces in a matrix
pairs = J( totalProds, totalProds, 0 );
For( irow = 1, irow <= N Rows( dt ), irow += 1,
p = dt:purchases[irow]; // p is a list from the data table
While( N Items( p ) >= 2, // as long as p has at least 2 items
pairs[p[1], p[2]] += 1; // use the first two as indexes to the pairs matrix
Remove From( p, 1 ); // remove the first item from p
);
);
Show( pairs ); // display the matrix
// sumarize the results
For( i = 1, i <= totalProds, i += 1,
Write( "\!nlast purchase: ", i, " suggests next purchase: ", Loc Max( pairs[i, 0] ) )
);
마지막 줄에는 약간의 설명이 필요할 수 있습니다. pairs [i, 0]은 행 i와 모든 열을 의미합니다. LocMax는 최대 값의 위치를 반환하는 함수입니다. 제품 번호는 1부터 시작하기 때문에 제품 i를 구입 한 후 가장 자주 구매 한 제품 번호이기도합니다.