Python: Ecommerce: Part — 5: Calculate Your Sell Prices for Ebay and Amazon

Please read the other articles for this series.

Code will be given cell by cell from Jupyter Notebook. Then will also give all code in one block. You might need to adjust the indenting a bit.

Read the code comments as well. Comments explained the sections.

Calculate sell prices (and related) for ebay

In [46]:

ebay_profit_tax = U2 * income_taxAB2 = price_calculation_df['ebay_cost'] = round(L2 + N2 + O2 + P2 + S2 + ebay_profit_tax, 2)W2[:5], AB2[:5]L2[:1], M2[:1], N2[:1], P2[:1], S2[:1], V2[:1]

Out[46]:

(0    548.29
 dtype: float64, 0    54.829
 Name: Total with ship, dtype: float64, 0    16.7487
 Name: Total with ship, dtype: float64, 0    5.4829
 Name: Total with ship, dtype: float64, 0    16.4487
 Name: Total with ship, dtype: float64, 0    27.4145
 Name: shopforsoul_profit, dtype: float64)

In [47]:

AC2 = price_calculation_df['ebay_list_price'] = round(AB2 + U2 -F2, 2) # - F2, 2)AC2[:5]

Out[47]:

0    262.43
1    263.43
2    258.56
3    258.43
4    259.65
dtype: float64

In [48]:

AD2 = price_calculation_df['Buyer pay from Mall'] = round(Y2+R2,2)

In [49]:

AE2 = price_calculation_df['Ebay Buyers Pay'] = round(AC2+R2+F2,2)AF2 = price_calculation_df['Ebay vs Mall'] = round(AE2-AD2, 2)

account for amazon selling cost and calculate your sell price for amazon

#amazon has sales commission to pay

#you might want to account for monthly subscription fee (based on how much you sell in a month and how much subscription fee you pay)

In [50]:

# possible income taxAG2 = price_calculation_df['NA-1'] = round(W2-R2+L2*0.2,2)AI2 = price_calculation_df['amazon_profit'] = round(L2*amazon_profit, 2)AJ2 = price_calculation_df['amazon_our_cost'] = round(L2+S2+P2+R2+AI2*income_tax,2)AH2 = price_calculation_df['Amazon Final Value Fee'] = round( (AI2 + AJ2) * amazon_final_fee_rate, 2)AK2 = price_calculation_df['amazon_list_price'] = round(AJ2+AI2+AH2, 2)AL2 = price_calculation_df['amazon_special_price'] = round(L2*amazon_special_profit+AJ2+(L2*amazon_special_profit+AJ2)*income_tax+L2*amazon_special_profit*income_tax-L2*amazon_profit*income_tax, 2)AM2 = price_calculation_df['Amazon Final Value Fee USD'] = round(AH2*cad_to_usd, 2)AN2 = price_calculation_df['amazon_profit_usd'] = round(AI2*cad_to_usd, 2)AO2 = price_calculation_df['amazon_our_cost_usd'] = round(AJ2*cad_to_usd, 2)AP2 = price_calculation_df['amazon_list_price_usd'] = round(AK2*cad_to_usd, 2)AQ2 = price_calculation_df['amazon_special_price_usd'] = round(AL2*cad_to_usd, 2)

In [51]:

AE2[:2], AF2[:2] , AG2[:2] , AH2[:2] , AI2[:2] , AJ2[:2] , AK2[:2] ,AL2[:2] , AM2[:2] , AN2[:2] , AO2[:2] , AP2[:2] , AQ2[:2]

Out[51]:

(0    935.52
 1    936.76
 dtype: float64, 0    96.42
 1    96.55
 dtype: float64, 0    115.82
 1    115.97
 dtype: float64, 0    526.97
 1    527.67
 dtype: float64, 0    739.21
 1    740.19
 dtype: float64, 0    658.71
 1    659.59
 dtype: float64)

In [52]:

AR2 = price_calculation_df['amazon_list_price_gbp'] = round(AK2*cad_to_gbp, 2)AS2 = price_calculation_df['amazon_special_price_gbp'] = round(AL2*cad_to_gbp, 2)AT2 = price_calculation_df['amazon_list_price_eu'] = round(AK2*cad_to_euro,2)AU2 = price_calculation_df['amazon_special_price_eu'] = round(AL2*cad_to_euro, 2)AV2 = price_calculation_df['amazon_list_price_mxn'] = round(AK2*cad_to_mxn, 2)AW2 = price_calculation_df['amazon_special_price_mxn'] = round(AL2*cad_to_mxn, 2)AR2[:2], AS2[:2], AT2[:2], AU2[:2], AV2[:2], AW2[:2]

Out[52]:

(0    602.25
 1    603.04
 dtype: float64, 0    536.66
 1    537.37
 dtype: float64, 0    684.14
 1    685.05
 dtype: float64, 0    609.64
 1    610.45
 dtype: float64, 0    18468.44
 1    18492.89
 dtype: float64, 0    16457.20
 1    16479.01
 dtype: float64)

In [53]:

#D2 = 1BD2 = raw_df['Weight Kg']AX2 = price_calculation_df['ama_safe_refund_amount'] = round(AL2-H2-I2-K2-S2-P2-R2-AH2-D2-18, 2)AY2 = price_calculation_df['Weight'] = round(BD2*2.2, 2)BJ2 = price_calculation_df['original in stock'] = raw_df['Stock status']AZ2 = price_calculation_df['Stock status'] = (BJ2=="In Stock").astype(int)#AZ2 = AZ2.astype(int)AX2[:2], AY2[:2], AZ2[:2], BJ2[:2], BD2[:2]

Out[53]:

(0    573.29
 1    573.41
 dtype: float64, 0    0.09
 1    0.06
 Name: Weight Kg, dtype: float64, 0    0
 1    0
 Name: Stock status, dtype: int64, 0    Closed
 1       NaN
 Name: Stock status, dtype: object, 0    0.043
 1    0.025
 Name: Weight Kg, dtype: float64)

In [55]:

AY2[:5]

Out[55]:

0    0.09
1    0.06
2    0.09
3    0.09
4    0.09
Name: Weight Kg, dtype: float64

In [56]:

min_raw_price_to_show_on_amazon = 10BA2 = price_calculation_df['categories'] = raw_df['Category Name'] + '/' + raw_df['Subcategory Name']BB2 = price_calculation_df['_root_category'] = 'All'BC2 = price_calculation_df['visibility'] = 4vis = []for x in D2:if x < min_raw_price_to_show_on_amazon:#vis.append(1)# temporaryvis.append('Catalog, Search')else:vis.append('Catalog, Search')BC2 = price_calculation_df['visibility'] = vis# temporary# BC2 = price_calculation_df['visibility'] = 4

In [57]:

BC2[:5]

Out[57]:

['Catalog, Search',
 'Catalog, Search',
 'Catalog, Search',
 'Catalog, Search',
 'Catalog, Search']

In [61]:

# take width height from supplier to push to Amazon

In [62]:

BE2 = price_calculation_df['Height mm'] = raw_df['Height mm']BF2 = price_calculation_df['Width mm'] = raw_df['Width mm']BG2 = price_calculation_df['Depth mm'] = raw_df['Depth mm']

In [64]:

# We do not want to sell products that has weight > 40 lbs

# status = 2 = disabled on Amazon# based on 'weight right' products will be disabled or enabled

In [65]:

# default valueBH2 = price_calculation_df['status'] =  2BN2 = price_calculation_df['weight right'] = 0vis = []for x in AY2:if x <= 20:vis.append(1)else:vis.append(0)BN2 = price_calculation_df['weight right'] = visBN2[:5]

Out[65]:

[1, 1, 1, 1, 1]

In [66]:

# based on shipping cost, you might not want to sell products.

# we will not sell if the shipping cost is more than $40

In [67]:

vis = []for x in F2.astype(float):if x >= 40:vis.append(0)else:vis.append(1)BO2 = price_calculation_df['Ship Right'] = vis#if (F2 >= 40) and (D2/F2 <= 2):#BO2 = price_calculation_df['Ship Right'] = 0BO2[:5]

Out[67]:

[0, 0, 0, 0, 0]

In [60]:

# F2[2531]

In [68]:

# if the product will be discontinued soon, we are not selling.

# will set status = 2. initially will set Is Normal = No = 0

In [69]:

BM2 = price_calculation_df['Soon Discontinued'] = raw_df['Soon Discontinued']BP2 = price_calculation_df['Is Normal'] = 0vis = []for x in BM2:if x == 'Soon Discontinued':vis.append(0)else:vis.append(1)BP2 = price_calculation_df['Is Normal'] = visBP2[10603:10610]

Out[69]:

[0, 1, 1, 1, 1, 0, 0]

In [70]:

'''BH2 = [1] * len(BN2)for index in range(0, len(BN2) ):if (BN2[index]==1):if (BO2[index]==1):if (BP2[index]==1):if (AZ2[index]==1):BH2[index] =  1price_calculation_df['status'][index] = 1'''

Out[70]:

"\nBH2 = [1] * len(BN2)\nfor index in range(0, len(BN2) ):\n    if (BN2[index]==1):\n        if (BO2[index]==1):\n            if (BP2[index]==1):\n                if (AZ2[index]==1):\n                    BH2[index] =  1\n                    price_calculation_df['status'][index] = 1\n\n"

In [71]:

# set status for some or until now. Status = 2 = disabled

# status = enabled if all conditions are right i.e. BN2 and BO2 and BP2 and AZ2# i.e. price right, ship right, weight right, not discontinuedBH2 = BN2 and BO2 and BP2 and AZ2BH2.replace(0, 2, inplace=True)#sorted(BH2, reverse=True)price_calculation_df['status'] = BH2

In [72]:

# keep track of supplier retail price (recommended retail) and retail+shipping priceBI2 = price_calculation_df['Retail Price'] = raw_df['Retail Price']

In [73]:

BH2[1]  , raw_df[1:2]['Model Code']

Out[73]:

(2, 1    A01AL3303110
 Name: Model Code, dtype: object)

In [74]:

price_calculation_df['Retail Price'] = price_calculation_df['Retail Price'].astype(str)

In [75]:

#list(price_calculation_df['Retail Price'].unique()[0:len(price_calculation_df['Retail Price'])+1])BI2 = price_calculation_df['Retail Price'] = price_calculation_df['Retail Price'].str.replace(',','')#max(sorted(price_calculation_df['Retail Price'].astype(str)))BK2 = price_calculation_df['R+shipp'] = BI2.astype(float) + F2.astype(float) #price_calculation_df['Retail Price'] + price_calculation_df['cheapest_courier_shipping']

In [76]:

BK2[:5]

Out[76]:

0    516.77
1    517.48
2    513.00
3    512.92
4    513.97
dtype: float64

In [77]:

#F2# compare our retail shop = magento price with supplier recommended retail priceBL2 = price_calculation_df['Shop vs retail'] = Y2 - BK2 #round(W2+L2*0.15,22) #- price_calculation_df['Retail Price'] #- price_calculation_df['cheapest_courier_shipping']

Out[77]:

(0    234.68
 1    234.97
 2    234.65
 3    234.60
 4    234.74
 dtype: float64, 0    691.10
 1    692.04
 2    687.49
 3    687.38
 4    688.51
 dtype: float64, 0    486.61
 1    487.28
 2    484.07
 3    483.99
 4    484.79
 dtype: float64)

In [78]:

# calculate prices for Amazon

In [79]:

BQ2 = price_calculation_df['amazon_ca_minimum_price'] = round(AJ2-H2-K2-I2-P2-S2,2)usd_rate = 0.761242BR2 = price_calculation_df['amazon_usd_minimum_price'] = round(BQ2 * cad_to_usd, 2)BL2[:5], BQ2[:5], BR2[:5]

Out[79]:

(0    234.68
 1    234.97
 2    234.65
 3    234.60
 4    234.74
 dtype: float64, 0    691.10
 1    692.04
 2    687.49
 3    687.38
 4    688.51
 dtype: float64, 0    486.61
 1    487.28
 2    484.07
 3    483.99
 4    484.79
 dtype: float64)

In [80]:

BS2 = price_calculation_df['amazon_gbp_minimum_price'] = round(BQ2 * cad_to_gbp, 2)BT2 = price_calculation_df['amazon_eu_minimum_price'] = round(BQ2 * cad_to_euro, 2)BU2 = price_calculation_df['amazon_mxn_minimum'] = round(BQ2 * cad_to_mxn, 2)"""E2 = [500] * len(raw_df)min_e2_f2 = E2if F2.any() < min_e2_f2.any():min_e2_f2 = F2"""#BV2 = price_calculation_df['amazon_ca_abs_minimum'] = round(BQ2-R2+Q2-F2+ F2 )BW2 = price_calculation_df['expedited_cost'] = 45BU2[1]#[:5], BT2[:5], BU2[:5], BW2[:5]

Out[80]:

12174.02

In [81]:

BV2 = price_calculation_df['amazon_ca_abs_minimum'] = round ( BQ2 - R2 + Q2, 2)BV2[:5]

Out[81]:

0    625.31
1    626.16
2    622.03
3    621.93
4    622.96
dtype: float64

In [ ]:

# output Price Calculation

In [82]:

output_folder = './data-supplier-2020-04-14/output/'

In [83]:

price_calculation_df.to_csv( output_folder + 'calculated_price_' + input_file_name + today + '.csv')

In [84]:

df_calculated = pd.read_csv(output_folder + 'calculated_price_' + input_file_name + today + '.csv')df_calculated.head(2)

Out[84]:

Unnamed: 0product_idskuNameraw_pricePostal Shipping Pricecheapest_courier_shippingproduct_eanShip RiskPrice Risk…Retail PriceR+shippShop vs retailamazon_ca_minimum_priceamazon_usd_minimum_priceamazon_gbp_minimum_priceamazon_eu_minimum_priceamazon_mxn_minimumexpedited_costamazon_ca_abs_minimum0030399shopforsoul-A01AL3301111Black 3x3x3 MoYu AoLong V2 Puzzle-A01AL330111112.90500.0500.06.941378e+1215.00.3870…16.77516.77234.68691.10486.61396.45450.3612157.4945625.311138649shopforsoul-A01AL3303110Qiyun AoLong V2 3x3x3 Speed Cube Enhanced Edit…13.61500.0500.06.941378e+1215.00.4083…17.48517.48234.97692.04487.28396.99450.9712174.0245626.16

2 rows × 75 columns

In [85]:

price_calculation_df[['product_id', 'sku', 'Name']][:5]

Out[85]:

product_idskuName030399shopforsoul-A01AL3301111Black 3x3x3 MoYu AoLong V2 Puzzle-A01AL3301111138649shopforsoul-A01AL3303110Qiyun AoLong V2 3x3x3 Speed Cube Enhanced Edit…239296shopforsoul-A01CL3301111New , 5.46cm Smaller Sized Fangshi (Funs) Shua…337397shopforsoul-A01CL3302113Fangshi Shuanren 3 x 3 x 3 with Sticker 54.6 m…438354shopforsoul-A01CL3302120FangShi 3x3x3 Speed Cube Puzzle White Fully As…

# # Calculate sell prices (and related) for ebay# In[46]:ebay_profit_tax = U2 * income_tax
AB2 = price_calculation_df[‘ebay_cost’] = round(L2 + N2 + O2 + P2 + S2 + ebay_profit_tax, 2)
W2[:5], AB2[:5]
L2[:1], M2[:1], N2[:1], P2[:1], S2[:1], V2[:1]# In[47]:AC2 = price_calculation_df[‘ebay_list_price’] = round(AB2 + U2 -F2, 2) # — F2, 2)
AC2[:5]# In[48]:AD2 = price_calculation_df[‘Buyer pay from Mall’] = round(Y2+R2,2)# In[49]:AE2 = price_calculation_df[‘Ebay Buyers Pay’] = round(AC2+R2+F2,2)
AF2 = price_calculation_df[‘Ebay vs Mall’] = round(AE2-AD2, 2)# # account for amazon selling cost and calculate your sell price for amazon
# #amazon has sales commission to pay
# #you might want to account for monthly subscription fee (based on how much you sell in a month and how much subscription fee you pay)# In[50]:# possible income tax
AG2 = price_calculation_df[‘NA-1’] = round(W2-R2+L2*0.2,2)AI2 = price_calculation_df[‘amazon_profit’] = round(L2*amazon_profit, 2)
AJ2 = price_calculation_df[‘amazon_our_cost’] = round(L2+S2+P2+R2+AI2*income_tax,2)
AH2 = price_calculation_df[‘Amazon Final Value Fee’] = round( (AI2 + AJ2) * amazon_final_fee_rate, 2)
AK2 = price_calculation_df[‘amazon_list_price’] = round(AJ2+AI2+AH2, 2)
AL2 = price_calculation_df[‘amazon_special_price’] = round(L2*amazon_special_profit+AJ2+(L2*amazon_special_profit+AJ2)*income_tax+L2*amazon_special_profit*income_tax-L2*amazon_profit*income_tax, 2)
AM2 = price_calculation_df[‘Amazon Final Value Fee USD’] = round(AH2*cad_to_usd, 2)
AN2 = price_calculation_df[‘amazon_profit_usd’] = round(AI2*cad_to_usd, 2)
AO2 = price_calculation_df[‘amazon_our_cost_usd’] = round(AJ2*cad_to_usd, 2)
AP2 = price_calculation_df[‘amazon_list_price_usd’] = round(AK2*cad_to_usd, 2)
AQ2 = price_calculation_df[‘amazon_special_price_usd’] = round(AL2*cad_to_usd, 2)# In[51]:AE2[:2], AF2[:2] , AG2[:2] , AH2[:2] , AI2[:2] , AJ2[:2] , AK2[:2] , 
AL2[:2] , AM2[:2] , AN2[:2] , AO2[:2] , AP2[:2] , AQ2[:2]# In[52]:AR2 = price_calculation_df[‘amazon_list_price_gbp’] = round(AK2*cad_to_gbp, 2)
AS2 = price_calculation_df[‘amazon_special_price_gbp’] = round(AL2*cad_to_gbp, 2)
AT2 = price_calculation_df[‘amazon_list_price_eu’] = round(AK2*cad_to_euro,2)
AU2 = price_calculation_df[‘amazon_special_price_eu’] = round(AL2*cad_to_euro, 2)
AV2 = price_calculation_df[‘amazon_list_price_mxn’] = round(AK2*cad_to_mxn, 2)
AW2 = price_calculation_df[‘amazon_special_price_mxn’] = round(AL2*cad_to_mxn, 2)AR2[:2], AS2[:2], AT2[:2], AU2[:2], AV2[:2], AW2[:2]# In[53]:#D2 = 1
BD2 = raw_df[‘Weight Kg’] 
AX2 = price_calculation_df[‘ama_safe_refund_amount’] = round(AL2-H2-I2-K2-S2-P2-R2-AH2-D2–18, 2)
AY2 = price_calculation_df[‘Weight’] = round(BD2*2.2, 2)
BJ2 = price_calculation_df[‘original in stock’] = raw_df[‘Stock status’]
AZ2 = price_calculation_df[‘Stock status’] = (BJ2==”In Stock”).astype(int)
#AZ2 = AZ2.astype(int)
AX2[:2], AY2[:2], AZ2[:2], BJ2[:2], BD2[:2]# In[55]:AY2[:5]# In[56]:min_raw_price_to_show_on_amazon = 10
BA2 = price_calculation_df[‘categories’] = raw_df[‘Category Name’] + ‘/’ + raw_df[‘Subcategory Name’]
BB2 = price_calculation_df[‘_root_category’] = ‘All’
BC2 = price_calculation_df[‘visibility’] = 4vis = []
for x in D2:
 if x < min_raw_price_to_show_on_amazon:
 #vis.append(1)
 # temporary 
 vis.append(‘Catalog, Search’)
 else:
 vis.append(‘Catalog, Search’) 
BC2 = price_calculation_df[‘visibility’] = vis
# temporary
# BC2 = price_calculation_df[‘visibility’] = 4# In[57]:BC2[:5]# In[61]:# take width height from supplier to push to Amazon# In[62]:BE2 = price_calculation_df[‘Height mm’] = raw_df[‘Height mm’]
BF2 = price_calculation_df[‘Width mm’] = raw_df[‘Width mm’]
BG2 = price_calculation_df[‘Depth mm’] = raw_df[‘Depth mm’]# In[64]:# We do not want to sell products that has weight > 40 lbs
# status = 2 = disabled on Amazon
# based on ‘weight right’ products will be disabled or enabled# In[65]:# default value
BH2 = price_calculation_df[‘status’] = 2
BN2 = price_calculation_df[‘weight right’] = 0vis = []
for x in AY2:
 if x <= 20:
 vis.append(1)
 else:
 vis.append(0)BN2 = price_calculation_df[‘weight right’] = vis
BN2[:5]# In[66]:# based on shipping cost, you might not want to sell products. 
# we will not sell if the shipping cost is more than $40# In[67]:vis = []
for x in F2.astype(float):
 if x >= 40:
 vis.append(0)
 else:
 vis.append(1)
 
BO2 = price_calculation_df[‘Ship Right’] = vis
#if (F2 >= 40) and (D2/F2 <= 2):
 #BO2 = price_calculation_df[‘Ship Right’] = 0
 
BO2[:5]# In[60]:# F2[2531]# In[68]:# if the product will be discontinued soon, we are not selling.
# will set status = 2. initially will set Is Normal = No = 0# In[69]:BM2 = price_calculation_df[‘Soon Discontinued’] = raw_df[‘Soon Discontinued’] 
BP2 = price_calculation_df[‘Is Normal’] = 0vis = []
for x in BM2:
 if x == ‘Soon Discontinued’:
 vis.append(0)
 else:
 vis.append(1)
 
BP2 = price_calculation_df[‘Is Normal’] = vis 
BP2[10603:10610]# In[70]:‘’’
BH2 = [1] * len(BN2)
for index in range(0, len(BN2) ):
 if (BN2[index]==1):
 if (BO2[index]==1):
 if (BP2[index]==1):
 if (AZ2[index]==1):
 BH2[index] = 1
 price_calculation_df[‘status’][index] = 1‘’’# In[71]:# set status for some or until now
# status = enabled if all conditions are right i.e. BN2 and BO2 and BP2 and AZ2
# i.e. price right, ship right, weight right, not discontinued
BH2 = BN2 and BO2 and BP2 and AZ2
BH2.replace(0, 2, inplace=True)
#sorted(BH2, reverse=True)
price_calculation_df[‘status’] = BH2# In[72]:# keep track of supplier retail price (recommended retail) and retail+shipping price
BI2 = price_calculation_df[‘Retail Price’] = raw_df[‘Retail Price’]# In[73]:BH2[1] , raw_df[1:2][‘Model Code’]# In[74]:price_calculation_df[‘Retail Price’] = price_calculation_df[‘Retail Price’].astype(str)# In[75]:#list(price_calculation_df[‘Retail Price’].unique()[0:len(price_calculation_df[‘Retail Price’])+1])
BI2 = price_calculation_df[‘Retail Price’] = price_calculation_df[‘Retail Price’].str.replace(‘,’,’’)#max(sorted(price_calculation_df[‘Retail Price’].astype(str)))
BK2 = price_calculation_df[‘R+shipp’] = BI2.astype(float) + F2.astype(float) #price_calculation_df[‘Retail Price’] + price_calculation_df[‘cheapest_courier_shipping’]# In[76]:BK2[:5]# In[77]:#F2
# compare our retail shop = magento price with supplier recommended retail price
BL2 = price_calculation_df[‘Shop vs retail’] = Y2 — BK2 #round(W2+L2*0.15,22) #- price_calculation_df[‘Retail Price’] #- price_calculation_df[‘cheapest_courier_shipping’]# In[78]:# calculate prices for Amazon# In[79]:BQ2 = price_calculation_df[‘amazon_ca_minimum_price’] = round(AJ2-H2-K2-I2-P2-S2,2)
usd_rate = 0.761242
BR2 = price_calculation_df[‘amazon_usd_minimum_price’] = round(BQ2 * cad_to_usd, 2)
BL2[:5], BQ2[:5], BR2[:5]# In[80]:BS2 = price_calculation_df[‘amazon_gbp_minimum_price’] = round(BQ2 * cad_to_gbp, 2)
BT2 = price_calculation_df[‘amazon_eu_minimum_price’] = round(BQ2 * cad_to_euro, 2)
BU2 = price_calculation_df[‘amazon_mxn_minimum’] = round(BQ2 * cad_to_mxn, 2)“””
E2 = [500] * len(raw_df)
min_e2_f2 = E2
if F2.any() < min_e2_f2.any():
 min_e2_f2 = F2
“””#BV2 = price_calculation_df[‘amazon_ca_abs_minimum’] = round(BQ2-R2+Q2-F2+ F2 )
BW2 = price_calculation_df[‘expedited_cost’] = 45
BU2[1]#[:5], BT2[:5], BU2[:5], BW2[:5]# In[81]:BV2 = price_calculation_df[‘amazon_ca_abs_minimum’] = round ( BQ2 — R2 + Q2, 2) 
BV2[:5]# In[ ]:# output Price Calculation# In[82]:output_folder = ‘./data-supplier-2020–04–14/output/’# In[83]:price_calculation_df.to_csv( output_folder + ‘calculated_price_’ + input_file_name + today + ‘.csv’)# In[84]:df_calculated = pd.read_csv(output_folder + ‘calculated_price_’ + input_file_name + today + ‘.csv’)
df_calculated.head(2)# In[85]:price_calculation_df[[‘product_id’, ‘sku’, ‘Name’]][:5]

Medium: https://medium.com/@SayedAhmedCanada

*** . *** *** . *** . *** . ***

Sayed Ahmed

BSc. Eng. in Comp. Sc. & Eng. (BUET)

MSc. in Comp. Sc. (U of Manitoba, Canada)

MSc. in Data Science and Analytics (Ryerson University, Canada)

Linkedinhttps://ca.linkedin.com/in/sayedjustetc

Bloghttp://Bangla.SaLearningSchool.comhttp://SitesTree.com

Training Courses: http://Training.SitesTree.com

8112223 Canada Inc/Justetchttp://JustEtc.net

Facebook Groups/Forums to discuss (Q & A):

https://www.facebook.com/banglasalearningschool

https://www.facebook.com/justetcsocial

Get access to courses on Big Data, Data Science, AI, Cloud, Linux, System Admin, Web Development and Misc. related. Also, create your own course to sell to others. http://sitestree.com/training/

Build Ecommerce Software and Systems

Build Ecommerce Software and Systems

8112223 Canada Inc. (Justetc)

WRITTEN BY

Software Engineer, Data Scientist, Machine Learning Engineer.

Build Ecommerce Software and Systems

Build Ecommerce Software and Systems

Write the first response

More From Medium