Categories
Mastering Development

Cox proportional hazard model

I am trying to run Cox proportional hazard model on a data of 4 groups. Here’s the data: I am using this code: time_Allo_NHL<- c(28,32,49,84,357,933,1078,1183,1560,2114,2144) censor_Allo_NHL<- c(rep(1,5), rep(0,6)) time_Auto_NHL<- c(42,53,57,63,81,140,176,210,252,476,524,1037) censor_Auto_NHL<- c(rep(1,7), rep(0,1), rep(1,1), rep(0,1), rep(1,1), rep(0,1)) time_Allo_HOD<- c(2,4,72,77,79) censor_Allo_HOD<- c(rep(1,5)) time_Auto_HOD<- c(30,36,41,52,62,108,132,180,307,406,446,484,748,1290,1345) censor_Auto_HOD<- c(rep(1,7), rep(0,8)) myData <- data.frame(time=c(time_Allo_NHL, time_Auto_NHL, time_Allo_HOD, time_Auto_HOD), censor=c(censor_Allo_NHL, censor_Auto_NHL, censor_Allo_HOD, […]

Categories
Mastering Development

django admin panel image field produces wrong path to image

I have an image field that uploads to the media/ directory. In the django admin panel, it links to admin/api/character/2/change/media/image.jpg, instead of media/image.jpg. How do I correct this? edit: the html are all default django admin templates. in fact, nothing about this is special. the imagefield is straight django. the admin template is straight django. […]

Categories
Ask Mathematics

Properties of sequences associated to Nakayama algebras

Assume Nakayama algebras are connected and given by quiver and relations. Note that such Nakayama algebras have global dimension at most $2n-2$ in case it is finite and the algebra has $n$ simples. For $n$ fixed and $1 \leq k \leq 2n-2$ let $a_{n,k}$ be the minimal vector space dimension of a Nakayama algebra with […]

Categories
Mastering Development

How to bind list objects inside Models in Xamarin

I have the following problem, in which I’m trying to Data Bind a List inside a Model to my xaml file. I want to bind the list of IOSensors to the xaml file in some text labels. Model: class IOModule { public IOModule(string Name, string Type, string Version, string Location, string Desc) { this.Name = […]

Categories
CMS Development Magento

“Could not receive Stock Item data” Line Appear Instead of Admin Product Grid – Magento 2

“Could not receive Stock Item data” line appear instead of product grid in admin side. I have recently imported other db to my Cloud local setup. When I am doing indexing,I am getting error like this. SQLSTATE[HY000]: General error: 1449 The user specified as a definer (”@’%’) do es not exist, query was: DELETE price_index […]

Categories
Ask Mathematics

Primitive Pythagorean triples and connection with prime numbers

On the Wikipedia page $16$ Pythagorean triples with $c \leq 100$ are listed: $$(3, 4, 5), (5, 12, 13), (8, 15, 17), (7, 24, 25), (20, 21, 29), (12, 35, 37), (9, 40, 41), (28, 45, 53), (11, 60, 61), (16, 63, 65), (33, 56, 65), (48, 55, 73), (13, 84, 85), (36, 77, 85), […]

Categories
Ask Mathematics

Primitive Pythagorean triples and connection with prime numbers

On the Wikipedia page $16$ Pythagorean triples with $c \leq 100$ are listed: $$(3, 4, 5), (5, 12, 13), (8, 15, 17), (7, 24, 25), (20, 21, 29), (12, 35, 37), (9, 40, 41), (28, 45, 53), (11, 60, 61), (16, 63, 65), (33, 56, 65), (48, 55, 73), (13, 84, 85), (36, 77, 85), […]

Categories
Ask Mathematics

Primitive Pythagorean triples and connection with prime numbers

On the Wikipedia page $16$ Pythagorean triples with $c \leq 100$ are listed: $$(3, 4, 5), (5, 12, 13), (8, 15, 17), (7, 24, 25), (20, 21, 29), (12, 35, 37), (9, 40, 41), (28, 45, 53), (11, 60, 61), (16, 63, 65), (33, 56, 65), (48, 55, 73), (13, 84, 85), (36, 77, 85), […]

Categories
Development

How contour an image area with known coordenates?

I have an ultrasound image and the coordenates (array of x and y points) of the tumour of each image. How can I make a contour around the tumour with those known coordenates using “cv.drawContours()”? I wish to delete all the information around the tumour and stay only with the tumour image/information. temp=np.array([[284., 60.],[276., 59.],[269., […]

Categories
Development

python: replace multiple columns in pandas frame with values form dictionary

import pandas as pd df = pd.DataFrame([[1,’192.168.1.10′, ‘45.7.12.34’, ‘abc’],[4, ‘10.10.1.11’, ‘90.90.67.33’, ‘def’], [77, ‘52.1.7.90’, ‘67.5.3.5’, ‘ghi’ ], [90, ‘19.19.90.7’, ‘77.88.99.44’, ‘xyz’]], columns=[‘A’, ‘sip’, ‘dip’, ‘location’]) addrs = {‘192.168.1.10’: ‘myhost.net’, ‘45.7.12.34’: ‘myhost-goo.net’, ‘10.10.1.11’: ‘myhost-foo.net’ }`enter code here` df[[‘sip’,’dip’]].replace(addrs, inplace=True) This code returns the warning, and in fact it does not replace dataframe‘s cell values: /usr/lib/python3.5/site-packages/pandas/core/frame.py:4042: SettingWithCopyWarning: […]