[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

mathematica tips and tricks

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 11
Thread images: 2

File: mathematica.jpg (20KB, 480x360px) Image search: [Google]
mathematica.jpg
20KB, 480x360px
I have 2 matrix from 2 different grayscaled Imagedata.
i merged in a single matrix qq and now i must apply a formula that was sent to me today as ColorFunction.


ColorFunction -> (RGBColor[1 - 1/3 #[Alpha], 1 - #[Alpha], 1 - #[Alpha]] /. [Alpha] -> 0.9 &)


i never used this option and when i try using it i get only errors, i tried with

ColorConvert[Image[qq],ColorFunction -> (RGBColor[1 - 1/3 #[Alpha], 1 - #[Alpha], 1 - #[Alpha]] /. [Alpha] -> 0.9 &)]

i am just a novice in mathematica
how should i solve this problem?
>>
>>8066262
Try
ColorConvert[Image[qq], ColorFunction -> (RGBColor[1 - 1/3 # 0.9, 1 - # 0.9, 1 - # 0.9])&]
>>
>>8066274
ColorConvert::imgcstype: ColorFunction->RGBColor[1-Power[<<2>>] #1 0.9,1-#1 0.9,1-#1 0.9]& is an invalid color space specification.

nope just errors
>>
>>8066284
Well then there's something wrong with the output the color function is producing.

Do you know what it's supposed to do? Do you have examples?
>>
Actually did you even read the documentation for ColorConvert?

https://reference.wolfram.com/language/ref/ColorConvert.html

I don't think it's supposed to take a ColorFunction
>>
>>8066297
then what command has this function since it change the color?
>>
>>8066293
like background of pic related
>>
>>8066311
Just map your function over the pixels.
>>
>>8066330
how the fuck do i do it?
>>
File: Capture.png (32KB, 709x668px) Image search: [Google]
Capture.png
32KB, 709x668px
>>8066333
Like this

Replace f with your whatever color function you are trying to use, and use the correct numbers for the partitioning
>>
>>8066344
thanks
Thread posts: 11
Thread images: 2


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.